Skip to content
This repository was archived by the owner on Mar 1, 2023. It is now read-only.

Add HEROKU_REGION to configure app region #221

Merged
merged 1 commit into from
Apr 19, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion deployment/deploy-heroku.sh
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"

APP_HOST=$1
SESSION_TIME=${SESSION_TIME:-'""'}
HEROKU_REGION=${HEROKU_REGION:-'us'}

ASSETS_DIR="$SCRIPT_DIR/../assets"
CONFIG_DIR="$SCRIPT_DIR/config"
Expand All @@ -56,7 +57,7 @@ cp "$CONFIG_DIR/Procfile" "$ASSETS_DIR"
###################

pushd "$ASSETS_DIR"
heroku create ${APP_HOST} --buildpack https://github.com/heroku/heroku-buildpack-ruby.git#v200
heroku create ${APP_HOST} --buildpack https://github.com/heroku/heroku-buildpack-ruby.git#v200 --region ${HEROKU_REGION}
heroku addons:create heroku-postgresql:hobby-dev -a ${APP_HOST}
heroku addons:create heroku-redis:hobby-dev -a ${APP_HOST}
heroku config:set WEBSOCKET_PORT=4443 SESSION_TIME=${SESSION_TIME} -a ${APP_HOST}
Expand Down