How to Configure Caddy External

I’ve got this as my docker-compose.yml file:

    image: nextcloud/all-in-one:latest
    init: true
    restart: always
    container_name: nextcloud-aio-mastercontainer
      - nextcloud_aio_mastercontainer:/mnt/docker-aio-config
      - /var/run/docker.sock:/var/run/docker.sock:ro
      - 8080:8080
      APACHE_PORT: 11000
      NEXTCLOUD_MOUNT: /mnt/

    name: nextcloud_aio_mastercontainer

I set my Caddyfile (which is running on the machine, not as a container… to reverse_proxy my to localhost:11000, but this doesn’t allow me to access the site. I get this error from Caddy logs:

May 20 12:20:09 blackbox caddy[665]: {"level":"error","ts":1716225609.3699536,"logger":"http.log.error","msg":"read tcp [::1]:42564->[::1]:11000: read: connection reset by peer","request">

I also tried to expose port - 11000:11000 and point the reverse_proxy there, but that doesn’t work either. How can I get this configured?

Hi, can you follow all-in-one/ at main · nextcloud/all-in-one · GitHub?

This is the solution I have followed, and I’ve configured both my Caddy server and the docker-compose file according to it’s instructions. The issue remains.

Have you already done step 4?

Yes, as I originally stated I made sure the reverse proxy matched the APACHE_PORT env variable. I also exposed that port but it did not fix the issue.

So what happens if you type in your domain in the aio interface on port 8080?

Firefox refuses to navigate to it since the certificate is self-signed.

Yeah, you need to use https://ip.address.of.server:8080 and acvcept the self-signed certificate

1 Like