The postgres container creates the database, but the nextcloud installer wants ton create the DB itself… So we have to tell to postgres to create a dummy DB. ref https://github.com/nextcloud/docker/issues/456
@@ -5,7 +5,6 @@ https://nextcloud.com/
## Configure
```
echo POSTGRES_PASSWORD=$(openssl rand -base64 32) >> .env
-echo POSTGRES_DB=nextcloud >> .env
echo POSTGRES_USER=nextcloud >> .env
echo POSTGRES_HOST=db >> .env
@@ -8,6 +8,8 @@ services:
db:
image: postgres:10-alpine
restart: unless-stopped
+ environment:
+ - POSTGRES_DB=workaround # nextcloud wants to create the db itself
env_file:
- .env
volumes:
@@ -16,6 +18,8 @@ services:
app:
image: nextcloud:fpm-alpine
+ - POSTGRES_DB=nextcloud