Nextcloud-aio-mastercontainer port is conflicting with itself - "Domaincheck container is not running"

Version: 12.1.4 Beta
(I was getting slim application error on the most stable release. At least this got me to the setup page.)

Context

This is my first time setting up Nextcloud. This could very well (and likely is) an issue with me setting it up incorrectly.

I am using Caddy to point external.domain.org to my apache port (11000) that I want to use for Nextcloud, and an internal url (192.168.0.177:8081) to point to Nextclouds local url (192.168.0.177:8080) so I could connect to that one with https.

Steps to reproduce

  1. Run nextcloud-aio-mastercontainer with an open apache port (ex. 11000)
  2. Navigate to its own local address (ex. 8080)

Expected behavior

The container is created, and properly accesses the port without conflicts. I can log in to localhost:8080 and set up nextcloud normally.

Actual behavior

No matter what port I use, I get this error page:

Nextcloud AIO v12.1.4
Domaincheck container is not running

This is not expected. Most likely this happened because port 11000 is already in use on your server. You can check the mastercontainer logs and domaincheck container logs for further clues. You should be able to resolve this by adjusting the APACHE_PORT by following the reverse proxy documentation. Advice: have a detailed look at the changed docker run command for AIO.

How to reset the AIO instance?

If something should be going wrong, for example during the initial installation, you can reset the instance by following this documentation.

Every time before I set a port I check to see if it is available.
nate@Computer:~$ sudo docker ps -a | grep 11000
and after building the docker container again, I check again.

nate@Computer:~$ sudo docker ps -a | grep 11000
ee88c04e8d77   ghcr.io/nextcloud-releases/all-in-one:beta          "/start.sh"              21 minutes ago   Up 21 minutes (healthy)    0.0.0.0:8080->8080/tcp, [::]:8080->8080/tcp, 80/tcp, 0.0.0.0:8443->8443/tcp, [::]:8443->8443/tcp, 9000/tcp, 0.0.0.0:**11000**->**11000**/tcp, [::]:**11000**->**11000**/tcp   nextcloud-aio-mastercontainer

The only container it is conflicting with is itself. The one it created.

Other information

Host OS

Linux Mint Xfce 22.2

Output of sudo docker info

nate@Computer:~$ sudo docker info
Client: Docker Engine - Community
 Version:    29.0.4
 Context:    default
 Debug Mode: false
 Plugins:
  buildx: Docker Buildx (Docker Inc.)
    Version:  v0.30.0
    Path:     /usr/libexec/docker/cli-plugins/docker-buildx
  compose: Docker Compose (Docker Inc.)
    Version:  v2.40.3
    Path:     /usr/libexec/docker/cli-plugins/docker-compose

Server:
 Containers: 17
  Running: 12
  Paused: 0
  Stopped: 5
 Images: 13
 Server Version: 29.0.4
 Storage Driver: overlay2
  Backing Filesystem: extfs
  Supports d_type: true
  Using metacopy: false
  Native Overlay Diff: true
  userxattr: false
 Logging Driver: json-file
 Cgroup Driver: systemd
 Cgroup Version: 2
 Plugins:
  Volume: local
  Network: bridge host ipvlan macvlan null overlay
  Log: awslogs fluentd gcplogs gelf journald json-file local splunk syslog
 CDI spec directories:
  /etc/cdi
  /var/run/cdi
 Discovered Devices:
  cdi: nvidia.com/gpu=0
  cdi: nvidia.com/gpu=GPU-4be8d7c3-3523-656c-8b30-48afa98c7cb1
  cdi: nvidia.com/gpu=all
 Swarm: inactive
 Runtimes: io.containerd.runc.v2 nvidia runc
 Default Runtime: runc
 Init Binary: docker-init
 containerd version: fcd43222d6b07379a4be9786bda52438f0dd16a1
 runc version: v1.3.3-0-gd842d771
 init version: de40ad0
 Security Options:
  apparmor
  seccomp
   Profile: builtin
  cgroupns
 Kernel Version: 6.14.0-35-generic
 Operating System: Linux Mint 22.2
 OSType: linux
 Architecture: x86_64
 CPUs: 8
 Total Memory: 31.2GiB
 Name: Computer
 ID: fca78a93-4b12-4c2c-9057-9a206c10c0db
 Docker Root Dir: /var/lib/docker
 Debug Mode: false
 Experimental: false
 Insecure Registries:
  ::1/128
  127.0.0.0/8
 Live Restore Enabled: false
 Firewall Backend: iptables

Docker run command or docker-compose file that you used

services:
  nextcloud-aio-mastercontainer:
    image: ghcr.io/nextcloud-releases/all-in-one:beta
    container_name: nextcloud-aio-mastercontainer
    restart: always
    init: true
    ports:
      - "8080:8080"
      - "8443:8443"
      - "11000:11000"
    environment:
      - SKIP_DOMAINCHECK=true
      - NEXTCLOUD_UPLOAD_LIMIT=32G
      - NEXTCLOUD_MAX_TIME=7200
      - NEXTCLOUD_MEMORY_LIMIT=1024M
      - NEXTCLOUD_ENABLE_DRI_DEVICE=true
      - SKIP_IP_CHECK=true
      - APACHE_PORT=11000
    volumes:
      - nextcloud_aio_mastercontainer:/mnt/docker-aio-config
      - /var/run/docker.sock:/var/run/docker.sock:ro
      - /mnt/storage-share/
    deploy:
      resources:
        reservations:
          devices:
            - driver: nvidia
              count: all
              capabilities: [gpu]

volumes:
  nextcloud_aio_mastercontainer:
    name: nextcloud_aio_mastercontainer

Caddyfile you used

and the only way I can connect to the server at all with Caddy is if I skip the tls verification. Here is the relevant snippet of my caddyfile.

...
#Nextcloud External
external.domain.org {
    reverse_proxy https://127.0.0.1:11000 {
        transport http {
            tls_insecure_skip_verify
        }
    }
}

#Nextcloud Local
192.168.0.177:8081 {
    reverse_proxy https://127.0.0.1:8080 {
        transport http {
            tls_insecure_skip_verify
        }
    }
}

Output of sudo docker logs nextcloud-aio-mastercontainer

nate@Computer:~$ sudo docker logs nextcloud-aio-mastercontainer
Trying to fix docker.sock permissions internally...
Creating docker group internally with id 985
Initial startup of Nextcloud All-in-One complete!
You should be able to open the Nextcloud AIO Interface now on port 8080 of this server!
E.g. https://internal.ip.of.this.server:8080
⚠️ Important: do always use an ip-address if you access this port and not a domain as HSTS might block access to it later!

If your server has port 80 and 8443 open and you point a domain to your server, you can get a valid certificate automatically by opening the Nextcloud AIO Interface via:
https://your-domain-that-points-to-this-server.tld:8443
/usr/lib/python3.12/site-packages/supervisor/options.py:13: UserWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html. The pkg_resources package is slated for removal as early as 2025-11-30. Refrain from using this package or pin to Setuptools<81.
  import pkg_resources
[Wed Nov 26 21:25:03.850560 2025] [mpm_event:notice] [pid 178:tid 178] AH00489: Apache/2.4.65 (Unix) OpenSSL/3.5.4 configured -- resuming normal operations
[Wed Nov 26 21:25:03.850591 2025] [core:notice] [pid 178:tid 178] AH00094: Command line: 'httpd -D FOREGROUND'
[26-Nov-2025 21:25:03] NOTICE: fpm is running, pid 184
[26-Nov-2025 21:25:03] NOTICE: ready to handle connections
{"level":"info","ts":1764192303.8543856,"msg":"maxprocs: Leaving GOMAXPROCS=8: CPU quota undefined"}
{"level":"info","ts":1764192303.8545113,"msg":"GOMEMLIMIT is updated","package":"github.com/KimMachineGun/automemlimit/memlimit","GOMEMLIMIT":30151950336,"previous":9223372036854775807}
{"level":"info","ts":1764192303.8545372,"msg":"using config from file","file":"/Caddyfile"}
{"level":"info","ts":1764192303.8553994,"msg":"adapted config to JSON","adapter":"caddyfile"}
{"level":"info","ts":1764192303.8569372,"msg":"serving initial configuration"}
NOTICE: PHP message: Could not start domaincheck container: Could not start container nextcloud-aio-domaincheck: {"message":"failed to set up container networking: driver failed programming external connectivity on endpoint nextcloud-aio-domaincheck (235e0b825bd08441279a3c45cba1f9ac9ef691145a373e15a3aa1d62afc6e580): Bind for :::11000 failed: port is already allocated"}
NOTICE: PHP message: Could not start domaincheck container: Could not start container nextcloud-aio-domaincheck: {"message":"failed to set up container networking: driver failed programming external connectivity on endpoint nextcloud-aio-domaincheck (3186c5dd95df291723e533bcb7c14e6c64e1b1fe380de60b6e007bd0d7c7da34): Bind for 0.0.0.0:11000 failed: port is already allocated"}

Other valuable info

I think that’s about it. Hopefully.

Hi, removing this should make it work.

Also please check all-in-one/reverse-proxy.md at main · nextcloud/all-in-one · GitHub

Thank you! That got my container started. When I check my domain though I got the error

The domain is not reachable on Port 443 from within this container. Have you opened port 443/tcp in your router/firewall? If yes is the problem most likely that the router or firewall forbids local access to your domain. Or in other words: NAT loopback (Hairpinning) does not seem to work in your network. You can work around that by setting up a local DNS server and utilizing Split-Brain-DNS and configuring the daemon.json file of your docker daemon to use the local DNS server.

I know Caddy works perfectly fine and port 443 is open - I can access all of my other services ok, you just can’t access my external domain on the local network. When I set up a WiFi zone on my DNS server to route those requests locally I get another error that it is an internal domain. However, adding SKIP_DOMAIN_VALIDATION=true fixed that. I will be able to connect to that domain from anywhere.

I have a new question: How will I be able to access NextCloud if I do not bind it to port 11000? The APACHE_PORT is still 11000, but since I removed “11000:11000” how do I get directed to Nextcloud? I just installed all the Nextcloud containers and went through that setup, but when that page redirects me to the nextcloud domain (example.domain.org) - and even when I try to go to it directly using the internal url 192.168.0.177:11000 - I get a failed to connect to page, like there is nothing running there.

Have you checked this?

This is not right. Please review the AIO RP documentation again. The reverse_proxy destination should not be https.

The AIO mastercontainer orchestrates other containers, including the one that will handle the APACHE_PORT. The Compose file is only used to bootstrap the mastercontainer.

1 Like

I must not be very smart - I left that to mirror the 8080 local access because I was having trouble accessing it before. Now that I re-read it I am missing the specific :443 port binding in my caddyfile. I think I understand the container process now as well.
I got in.

Thanks everyone for your help, and sorry to have wasted your time!