passing params to the launcher gem

This commit is contained in:
bruckwubete
2018-07-09 13:17:23 -04:00
parent 930ed809f5
commit 67c32a396f
9 changed files with 45 additions and 16 deletions

View File

@ -1,9 +1,11 @@
#!/bin/bash
while [ "$RAILS_ENV" = "production" ] && ! curl http://$DB_HOST:5432/ 2>&1 | grep '52'
do
echo "Waiting for postgres to start up ..."
sleep 1
done
if [ "$RAILS_ENV" = "production" ]; then
while ! curl http://$DB_HOST:${DB_PORT:-5432}/ 2>&1 | grep '52'
do
echo "Waiting for postgres to start up ..."
sleep 1
done
fi
bundle exec rake db:create
bundle exec rake db:migrate