more
This commit is contained in:
parent
e2d9f6e682
commit
25f771cdd7
|
@ -1,13 +1,7 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
DB_HOST=${DATABASE_HOST:-postgres}
|
until nc -z ${DATABASE_HOST} ${DATABASE_PORT} > /dev/null; do
|
||||||
DB_PORT=${DATABASE_PORT:-5432}
|
echo "Waiting for database to become available on ${DATABASE_HOST}:${DATABASE_PORT}..."
|
||||||
|
|
||||||
BE_HOST=${BACKEND_HOST:-frogress}
|
|
||||||
BE_PORT=${BACKEND_PORT:-8000}
|
|
||||||
|
|
||||||
until nc -z ${DB_HOST} ${DB_PORT} > /dev/null; do
|
|
||||||
echo "Waiting for database to become available on ${DB_HOST}:${DB_PORT}..."
|
|
||||||
sleep 1
|
sleep 1
|
||||||
done
|
done
|
||||||
|
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
version: '2'
|
version: '2'
|
||||||
services:
|
services:
|
||||||
postgres:
|
postgres:
|
||||||
image: postgres:13-alpine
|
image: postgres:15.1-bullseye
|
||||||
environment:
|
environment:
|
||||||
POSTGRES_USER: frogress
|
POSTGRES_USER: ${POSTGRES_USER}
|
||||||
POSTGRES_PASSWORD: frogress
|
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
|
||||||
ports:
|
ports:
|
||||||
- "5432:5432"
|
- "${POSTGRES_PORT}:${POSTGRES_PORT}"
|
||||||
volumes:
|
volumes:
|
||||||
- ./deployment/postgres/data:/var/lib/postgresql/data
|
- ./deployment/postgres/data:/var/lib/postgresql/data
|
||||||
frogress:
|
frogress:
|
||||||
|
@ -14,4 +14,4 @@ services:
|
||||||
context: .
|
context: .
|
||||||
dockerfile: deployment/frogress/Dockerfile
|
dockerfile: deployment/frogress/Dockerfile
|
||||||
ports:
|
ports:
|
||||||
- "8000:8000"
|
- "${BACKEND_PORT}:${BACKEND_PORT}"
|
||||||
|
|
Loading…
Reference in New Issue