Skip to content

Commit 7b3b77e

Browse files
author
Robert Quander
committed
clear db before setting up, otherwise there#s a problem
1 parent 2e7c920 commit 7b3b77e

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

service/docker-compose.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,11 @@ services:
1717
# If things really need to be wiped, uncomment the destructive entrypoint below.
1818
# This will remove all old data in the database, and rebuild it from scratch.
1919
entrypoint: [ "bash", "-c", "\
20-
if [ ! -f /var/lib/postgresql/data/PG_VERSION ]; then \
21-
echo 'Database seems uninitialized. WIPING AND REBUILDING...'; \
20+
echo 'DESTROYING AND RESETTING DATABASE...'; \
2221
rm -rf /var/lib/postgresql/data/*; \
23-
fi; \
24-
exec docker-entrypoint.sh postgres " ]
22+
chown -R postgres:postgres /var/lib/postgresql/data; \
23+
exec docker-entrypoint.sh postgres \
24+
" ]
2525
healthcheck:
2626
test: ["CMD-SHELL", "pg_isready -U postgres"]
2727
interval: 30s

0 commit comments

Comments
 (0)