Hello
I want to run my nextcloud in separate containers. I followed the notes from github: https://github.com/nextcloud/docker/tree/master/.examples/docker-compose/insecure/postgres/fpm
Current state is that all containers start fine and do not report any issues. But I can not reach the nextcloud setup page under cloud.DOMAIN.ch. What I am receiving is the 404 page not found of nginx, so that should be working all right.
Postgres:
docker@docker:~$ docker container logs postgres
PostgreSQL Database directory appears to contain a database; Skipping initialization
2020-04-15 18:22:01.961 CEST [1] LOG: starting PostgreSQL 12.2 (Debian 12.2-2.pgdg100+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 8.3.0-6) 8.3.0, 64-bit
2020-04-15 18:22:01.969 CEST [1] LOG: listening on IPv4 address "0.0.0.0", port 5432
2020-04-15 18:22:01.969 CEST [1] LOG: listening on IPv6 address "::", port 5432
2020-04-15 18:22:01.979 CEST [1] LOG: listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
2020-04-15 18:22:02.026 CEST [26] LOG: database system was shut down at 2020-04-15 18:21:54 CEST
2020-04-15 18:22:02.040 CEST [1] LOG: database system is ready to accept connections
Nextcloud:
docker@docker:~$ docker container logs nextcloud
Initializing nextcloud 18.0.3.0 ...
Initializing finished
New nextcloud instance
[15-Apr-2020 16:53:56] NOTICE: fpm is running, pid 1
[15-Apr-2020 16:53:56] NOTICE: ready to handle connections
Nginx:
docker@docker:~$ docker container logs nginx
172.18.0.2 - - [15/Apr/2020:18:54:10 +0200] "GET / HTTP/1.1" 404 153 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:75.0) Gecko/20100101 Firefox/75.0" "XXX.XXX.98.43"
The corresponding docker-compose:
postgres:
container_name: postgres
image: postgres:latest
restart: always
volumes:
- ${CONFIG}/postgres:/var/lib/postgresql/data
networks:
- traefik_proxy
environment:
- PUID=${PUID}
- PGID=${PGID}
- TZ=Europe/Zurich
- PGDATA=/var/lib/postgresql/data/pgdata \
- POSTGRES_PASSWORD=nextcloud
- POSTGRES_DB=nextcloud
- POSTGRES_USER=nextcloud
nextcloud:
container_name: nextcloud
image: nextcloud:fpm-alpine
depends_on:
- postgres
networks:
- traefik_proxy
environment:
- PUID=${PUID}
- PGID=${PGID}
- TZ=Europe/Zurich
- POSTGRES_HOST=postgres
volumes:
- ${CONFIG}/nextcloud:/var/www/html
restart: always
nginx:
container_name: nginx
image: nginx:latest
volumes:
- ${CONFIG}/nginx/www:/var/www
- ${CONFIG}/nginx/:/etc/nginx
environment:
- PUID=${PUID}
- PGID=${PGID}
- TZ=Europe/Zurich
networks:
- traefik_proxy
restart: always
depends_on:
- nextcloud
networks:
- traefik_proxy
labels:
- traefik.enable=true
- traefik.http.services.nginx.loadbalancer.server.port=80
- traefik.docker.network=traefik_proxy
- traefik.http.routers.nginx.rule=Host(`cloud.DOMAIN.ch`)
- traefik.http.routers.nginx.entrypoints=https
- traefik.http.routers.nginx.priority=10
- traefik.http.routers.nginx.tls.certresolver=letsencrypt
- traefik.http.routers.nginx.tls.domains[0].main=*.DOMAIN.ch
- traefik.http.routers.nginx.tls.domains[0].sans=DOMAIN.ch
- traefik.http.middlewares.nginx.headers.SSLRedirect=true
- traefik.http.middlewares.nginx.headers.STSSeconds=315360000
- traefik.http.middlewares.nginx.headers.browserXSSFilter=true
- traefik.http.middlewares.nginx.headers.contentTypeNosniff=true
- traefik.http.middlewares.nginx.headers.forceSTSHeader=true
- traefik.http.middlewares.nginx.headers.SSLHost=
- traefik.http.middlewares.nginx.headers.STSIncludeSubdomains=true
- traefik.http.middlewares.nginx.headers.STSPreload=true
- traefik.http.middlewares.nginx.headers.frameDeny=true
What am I missing? It seems like nginx can’t read the FPM stream…
Thanks for any help!