Skip to content

Commit

Permalink
Merge pull request #84 from FinnStutzenstein/image
Browse files Browse the repository at this point in the history
Use official postgres 11 image
  • Loading branch information
FinnStutzenstein authored Jul 22, 2020
2 parents e5054e1 + fdf624f commit 147f02f
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 16 deletions.
6 changes: 3 additions & 3 deletions database.env
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
DB_USER=openslides
DB_PASS=openslides
DB_NAME=openslides
POSTGRES_USER=openslides
POSTGRES_PASSWORD=openslides
POSTGRES_DB=openslides
4 changes: 1 addition & 3 deletions dc.dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,7 @@ services:
- postgresql
- redis
postgresql:
image: sameersbn/postgresql:10
labels:
org.openslides.role: "postgres"
image: postgres:11
env_file: database.env
networks:
- postgresql
Expand Down
4 changes: 1 addition & 3 deletions dc.prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,7 @@ services:
- postgresql
- redis
postgresql:
image: sameersbn/postgresql:10
labels:
org.openslides.role: "postgres"
image: postgres:11
env_file: database.env
networks:
- postgresql
Expand Down
4 changes: 1 addition & 3 deletions dc.test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,7 @@ services:
networks:
- postgresql
postgresql:
image: sameersbn/postgresql:10
labels:
org.openslides.role: "postgres"
image: postgres:11
env_file: database.env
networks:
- postgresql
Expand Down
4 changes: 1 addition & 3 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,7 @@ services:
- postgresql
- redis
postgresql:
image: sameersbn/postgresql:10
labels:
org.openslides.role: "postgres"
image: postgres:11
env_file: database.env
networks:
- postgresql
Expand Down
5 changes: 4 additions & 1 deletion scripts/system/wait-for-database.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@

source export-database-variables.sh

wait-for-it -t 0 "$DATASTORE_DATABASE_HOST:$DATASTORE_DATABASE_PORT"
until pg_isready -h "$DATASTORE_DATABASE_HOST" -p "$DATASTORE_DATABASE_PORT"; do
echo "Waiting for Postgres server '$DATASTORE_DATABASE_HOST' to become available..."
sleep 3
done

# Create schema in postgresql
export PGPASSWORD="$DATASTORE_DATABASE_PASSWORD"
Expand Down

0 comments on commit 147f02f

Please sign in to comment.