Add files necessary for production deployment
* Dockerfile, docker-compose template * nginx config * uwsgi config * wait-for-postgres script * requirements.txt * Some other stuff Signed-off-by: Alek Ratzloff <alekratz@gmail.com>
This commit is contained in:
12
scripts/wait-for-postgres.sh
Executable file
12
scripts/wait-for-postgres.sh
Executable file
@@ -0,0 +1,12 @@
|
||||
#!/bin/sh
|
||||
# Hang until Postgres has started up.
|
||||
set -e
|
||||
|
||||
host="$1"
|
||||
shift
|
||||
|
||||
until PGPASSWORD="$POSTGRES_PASSWORD" psql -h "$host" -U "$POSTGRES_USER" -c '\q'; do
|
||||
sleep 1
|
||||
done
|
||||
|
||||
exec "$@"
|
||||
Reference in New Issue
Block a user