|
|
|
@ -27,6 +27,8 @@ steps:
|
|
|
|
|
PGDATABASE:
|
|
|
|
|
from_secret: db_database
|
|
|
|
|
commands:
|
|
|
|
|
- apt-get update && apt-get install -y postgresql-client
|
|
|
|
|
- until pg_isready -h marocher8-dbWikiFantasy -U postgres; do sleep 1; done
|
|
|
|
|
- psql -h marocher8-dbWikiFantasy -U postgres -d wikifantasy -f script/init.sql
|
|
|
|
|
- apt-get update && apt-get install -y postgresql-client netcat
|
|
|
|
|
- getent hosts dbwikifantasy
|
|
|
|
|
- until nc -z dbwikifantasy 5432; do echo "Waiting for port 5432..."; sleep 5; done
|
|
|
|
|
- until pg_isready -h dbwikifantasy -U postgres; do echo "En attente de PostgreSQL..."; sleep 5; done
|
|
|
|
|
- psql -h dbwikifantasy -U postgres -d wikifantasy -f script/init.sql
|
|
|
|
|