Hey folks,
The Basics
- Nextcloud Server version (e.g., 29.x.x):
- Hub 10
- Operating system and version (e.g., Ubuntu 24.04):
- latest arch
- Web server and version (e.g, Apache 2.4.25):
- Built in Apache
- Reverse proxy and version _(e.g. nginx 1.27.2)
- `traefik v3.4
- PHP version (e.g, 8.3):
- built in
- Is this the first time you’ve seen this error? (Yes / No):
- evertime I try it with differing configs
- When did this problem seem to first start?
- immeadiatly
- Installation method (e.g. AlO, NCP, Bare Metal/Archive, etc.)
- AIO latest
- Are you using CloudfIare, mod_security, or similar? (Yes / No)
- no
- Compose.yaml
services:
nextcloud-aio-mastercontainer:
image: nextcloud/all-in-one:latest
init: true
restart: always
container_name: nextcloud-aio-mastercontainer
volumes:
- nextcloud_aio_mastercontainer:/mnt/docker-aio-config
- /var/run/docker.sock:/var/run/docker.sock:ro
networks:
- proxy
- nextcloud-aio
ports:
- 8082:8080
environment
APACHE_PORT: 11000 # Is needed when running behind a web server or reverse proxy (like Apache, Nginx, Cadd
APACHE_IP_BINDING: 0.0.0.0
APACHE_ADDITIONAL_NETWORK: proxy
NEXTCLOUD_DATADIR: /mnt/extern/ncdata
NEXTCLOUD_MOUNT: /mnt/extern/
NEXTCLOUD_STARTUP_APPS: calendar contacts notes mail passwords
NEXTCLOUD_ADDITIONAL_APKS: imagemagick
NEXTCLOUD_ADDITIONAL_PHP_EXTENSIONS: imagick
SKIP_DOMAIN_VALIDATION: true
## labels:
# - "traefik.enable=true"
# - "traefik.docker.network=proxy"
networks:
proxy:
external: true
nextcloud-aio:
external: true
volumes:
nextcloud_aio_mastercontainer:
name: nextcloud_aio_mastercontainer
- Traefik Compose.yaml
services:
traefik:
image: "traefik:v3.2"
container_name: "traefik"
command:
- "--configFile=/etc/traefik/traefik.yaml"
ports:
- 80:80
- 8080:8080
- 443:443
volumes:
- "./letsencrypt:/letsencrypt"
- "/var/run/docker.sock:/var/run/docker.sock:ro"
- "./traefik_rules.yaml:/etc/traefik/rules.yaml"
- "./traefik.yaml:/etc/traefik/traefik.yaml"
- "./configs/nc_aio.yaml:/etc/traefik/nc_aio.yaml"
networks:
- proxy
extra_hosts:
- "host.docker.internal:host-gateway"
environment:
- "DESEC_TOKEN=my-api-key"
- "DESEC_ZONE=myzone.dedyn.io"
- "DESEC_HTTP_TIMEOUT=600"
- "DESEC_PROPAGATION_TIMEOUT=600"
- "DESEC_TTL=900"
- "DESEC_POLLING_INTERVAL=60"
restart: unless-stopped
labels:
- "traefik.enable=true"
- "traefik.http.routers.traefik.rule=Host(`traefik.server.local`)"
- "traefik.http.routers.traefik.entrypoints=websecure"
- "traefik.http.routers.traefik.tls=true"
- "traefik.http.routers.traefik.service=api@internal"
- "traefik.http.routers.traefik-secure.service=traefik"
- "traefik.http.services.traefik.loadbalancer.server.port=8080"
networks:
proxy:
driver: bridge
name: proxy
- Traefik dynamic conf for AIO
http:
routers:
nextcloud:
rule: "Host(`sub.myzone.dedyn.io`) || Host(`sub.server.local`)"
entrypoints:
- "websecure"
service: nextcloud
middlewares:
- nextcloud-chain
tls:
certresolver: "desec"
services:
nextcloud:
loadBalancer:
servers:
- url: "http://nextcloud-aio-apache:11000"
middlewares:
nextcloud-secure-headers:
headers:
hostsProxyHeaders:
- "X-Forwarded-Host"
referrerPolicy: "same-origin"
https-redirect:
redirectscheme:
scheme: websecure
nextcloud-chain:
chain:
middlewares:
- https-redirect
- nextcloud-secure-headers
Summary of the issue you are facing:
I got a problem reaching the nextcloud instance via web with AIO and traefik v3 (404 page not found).
AIO starts normally and can be reached via port 8082(8080). There I can adjust the addiotional container i want and everything is created as expected. Bu if I want to access the nextcloud instance itself, I get the 404 page not found error.
I got a ddns at desec and created a CNAME for AIO:
I tried APACHE IP BINDING with 127.0.0.1 and the Hosts IP. I also changed it in the traefik dynamic config to those. It did not help either.
I also added the commented labels for traefik in the AIO compose and it did not help either.
I read that hairpinning NAT is only needed for configurations without reverse proxy, so I did not configure that.
I tried several suggestions in this forum regarding trafik and AIO, but I di dnot get it working either.
This are the logs:
- Nextcloud
2025-05-10T05:22:35.159123897Z Waiting for nextcloud-aio-apache to become available...
2025-05-10T05:22:35.293908878Z [10-May-2025 05:22:35] NOTICE: fpm is running, pid 501
2025-05-10T05:22:35.293927260Z [10-May-2025 05:22:35] NOTICE: ready to handle connections
2025-05-10T05:22:50.162181143Z Connection to nextcloud-aio-apache (172.21.0.11) 11000 port [tcp/*] succeeded!
- Apache
2025-05-10T05:22:37.891886392Z Connection to nextcloud-aio-nextcloud (172.21.0.9) 9000 port [tcp/*] succeeded!
2025-05-10T05:22:39.266217036Z [Sat May 10 05:22:39.265539 2025] [mpm_event:notice] [pid 147:tid 147] AH00489: Apache/2.4.63 (Unix) configured -- resuming normal operations
2025-05-10T05:22:39.266477960Z [Sat May 10 05:22:39.265924 2025] [core:notice] [pid 147:tid 147] AH00094: Command line: '/usr/local/apache2/bin/httpd -D FOREGROUND'
2025-05-10T05:22:39.278230594Z {"level":"info","ts":1746854559.2779346,"msg":"using config from file","file":"/tmp/Caddyfile"}
2025-05-10T05:22:39.281151984Z {"level":"info","ts":1746854559.279732,"msg":"adapted config to JSON","adapter":"caddyfile"}
- Redis
2025-05-10T05:16:31.906721691Z Redis has started
- Traefik
2025-05-10T05:22:52Z DBG github.com/traefik/traefik/v3/pkg/provider/docker/pdocker.go:112 > Provider event received {Status:health_status: healthy ID:185610bafd435276fa553029154cd737aa2855e7cb7501e0a90eabece0837ed2 From:ghcr.io/nextcloud-releases/aio-nextcloud:latest Type:container Action:health_status: healthy Actor:{ID:185610bafd435276fa553029154cd737aa2855e7cb7501e0a90eabece0837ed2 Attributes:map[com.centurylinklabs.watchtower.enable:false image:ghcr.io/nextcloud-releases/aio-nextcloud:latest name:nextcloud-aio-nextcloud]} Scope:local Time:1746854572 TimeNano:1746854572290541139} providerName=docker
2025-05-10T05:22:52Z DBG github.com/traefik/traefik/v3/pkg/provider/docker/config.go:185 > Filtering disabled container container=nextcloud-aio-apache-8f46bd8f5b91246c1586ee03f50f0dc4da859ff5255226cc4d3235735209c92b providerName=docker
2025-05-10T05:22:52Z DBG github.com/traefik/traefik/v3/pkg/provider/docker/config.go:185 > Filtering disabled container container=nextcloud-aio-notify-push-1fa8ea839d7125c7e265f7e917d5db11340c5bfa1744524ca0ab72a989d95a55 providerName=docker
2025-05-10T05:22:52Z DBG github.com/traefik/traefik/v3/pkg/provider/docker/config.go:185 > Filtering disabled container container=nextcloud-aio-nextcloud-185610bafd435276fa553029154cd737aa2855e7cb7501e0a90eabece0837ed2 providerName=docker
2025-05-10T05:22:52Z DBG github.com/traefik/traefik/v3/pkg/provider/docker/config.go:185 > Filtering disabled container container=nextcloud-aio-imaginary-67dce2d0004a78e19f64d924202f8366fe69fe95f49a3b76f7aa86c568d6f6b8 providerName=docker
2025-05-10T05:22:52Z DBG github.com/traefik/traefik/v3/pkg/provider/docker/config.go:185 > Filtering disabled container container=nextcloud-aio-fulltextsearch-a0c05afc68bbd817a9ee96b8e699d030e62ec3116ffdaa56bbb6ed4eec72e2c7 providerName=docker
2025-05-10T05:22:52Z DBG github.com/traefik/traefik/v3/pkg/provider/docker/config.go:185 > Filtering disabled container container=nextcloud-aio-clamav-4361a0b7d4b7a9f911b4fa2acbc38b3a89c837223295df60846844e2cc317f44 providerName=docker
2025-05-10T05:22:52Z DBG github.com/traefik/traefik/v3/pkg/provider/docker/config.go:185 > Filtering disabled container container=nextcloud-aio-redis-878f6dbc0722deedc6950f1f57e639325422fda4f36d979f2a9208573e3dc979 providerName=docker
2025-05-10T05:22:52Z DBG github.com/traefik/traefik/v3/pkg/provider/docker/config.go:185 > Filtering disabled container container=nextcloud-aio-database-7f6c2bf44ecc79a510a7712d18d364b8b6185fcaa48bec0f7bd7cac5587f1ff2 providerName=docker
2025-05-10T05:22:52Z DBG github.com/traefik/traefik/v3/pkg/provider/docker/config.go:185 > Filtering disabled container container=nextcloud-aio-talk-4669a201d5b35064ca8d03d173bbdbb95d143f61d8da2ac708d06dd351daaa52 providerName=docker
2025-05-10T05:22:52Z DBG github.com/traefik/traefik/v3/pkg/provider/docker/config.go:185 > Filtering disabled container container=nextcloud-aio-mastercontainer-nextcloud-656844b63a6a9e4840162164623a3806584171c4a75649a12f3e82510235abf1 providerName=docker
- NC command within traefik
/ # nc -z nextcloud-aio-apache 11000; echo $?
0
/ # nc -z 127.0.0.1 11000; echo $?
1
/ # nc -z 192.168.178.4 11000; echo $?
0
I’d appreciae your help, but reffering to the reverse proxy reaadem won’t help for me, as I read it several times and did all what I understood there.
I thank you very much and best regards