Deploy to Heroku
This commit is contained in:
parent
07333806fc
commit
251d503358
16
deploy.sh
16
deploy.sh
@ -9,7 +9,21 @@ echo $WEB_URL
|
|||||||
# Add Heroku Postgres add-on
|
# Add Heroku Postgres add-on
|
||||||
heroku addons:create heroku-postgresql:essential-0 --app $APP_NAME
|
heroku addons:create heroku-postgresql:essential-0 --app $APP_NAME
|
||||||
|
|
||||||
echo echo $DATABASE_URL
|
|
||||||
|
while true; do
|
||||||
|
ADDON_STATUS=$(heroku addons:info heroku-postgresql --app $APP_NAME | grep 'State:' | awk '{print $2}')
|
||||||
|
echo "Postgres add-on state: $ADDON_STATUS"
|
||||||
|
|
||||||
|
if [ "$ADDON_STATUS" == "created" ]; then
|
||||||
|
echo "Heroku Postgres add-on is ready!"
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "Waiting for Postgres add-on to be ready..."
|
||||||
|
sleep 5
|
||||||
|
done
|
||||||
|
|
||||||
|
echo $DATABASE_URL
|
||||||
# Push to Heroku
|
# Push to Heroku
|
||||||
heroku git:remote --app $APP_NAME
|
heroku git:remote --app $APP_NAME
|
||||||
git add .
|
git add .
|
||||||
|
Loading…
Reference in New Issue
Block a user