Open
Description
I am using nginx-proxy and nginx-proxy-acme (along with other services). All services run at startup except for nginx-proxy-acme. To get it running I need to manually run docker compose up on my server (Debian 11). It then runs fine and renews my certs, however 3 months later it becomes an issue again as the certs expire because the service never runs.
Is this the default behaviour? I can't find anything in the docs to explain why it does not run at startup.
Below is my compose file:
version: "2.4"
services:
nginx-proxy:
image: nginxproxy/nginx-proxy
container_name: nginx-proxy
environment:
- PUID=${PUID}
- PGID=${PGID}
- TZ=${TZ}
volumes:
- /var/run/docker.sock:/tmp/docker.sock:ro
- ${USER_DIR}/.docker/nginx/certs:/etc/nginx/certs:rw
- ${USER_DIR}/.docker/nginx/vhost.d:/etc/nginx/vhost.d
- ${USER_DIR}/.docker/nginx/html:/usr/share/nginx/html
- ${USER_DIR}/.docker/nginx/conf:/etc/nginx/conf.d
ports:
- 80:80
- 443:443
restart: always
nginx-acme:
image: nginxproxy/acme-companion
container_name: nginx-proxy-acme
environment:
- PUID=${PUID}
- PGID=${PGID}
- TZ=${TZ}
- DEFAULT_EMAIL=${EMAIL}
volumes_from:
- nginx-proxy
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
- ${USER_DIR}/.docker/nginx/certs:/etc/nginx/certs:rw
- ${USER_DIR}/.docker/nginx/vhost.d:/etc/nginx/vhost.d
- ${USER_DIR}/.docker/nginx/html:/usr/share/nginx/html
- ${USER_DIR}/.docker/nginx/acme:/etc/acme.sh
restart: always
Container logs once manually started:
docker-compose logs nginx-acme
Attaching to nginx-proxy-acme
nginx-proxy-acme | Info: running acme-companion version v2.2.1
nginx-proxy-acme | Info: A custom dhparam.pem file was provided. Best practice is to use standardized RFC7919 Diffie-Hellman groups instead.
nginx-proxy-acme | Reloading nginx proxy (c03764d10903e7de5783d79a37fe9ba6be728fe3c60499bf2e5aa3c54ed16853)...
nginx-proxy-acme | 2022/09/13 10:50:26 Generated '/etc/nginx/conf.d/default.conf' from 16 containers
nginx-proxy-acme | 2022/09/13 10:50:26 [notice] 66#66: signal process started
nginx-proxy-acme | 2022/09/13 08:50:27 Generated '/app/letsencrypt_service_data' from 16 containers
nginx-proxy-acme | 2022/09/13 08:50:27 Running '/app/signal_le_service'
nginx-proxy-acme | 2022/09/13 08:50:27 Watching docker events
nginx-proxy-acme | 2022/09/13 08:50:28 Contents of /app/letsencrypt_service_data did not change. Skipping notification '/app/signal_le_service'
nginx-proxy-acme | Reloading nginx proxy (c03764d10903e7de5783d79a37fe9ba6be728fe3c60499bf2e5aa3c54ed16853)...
nginx-proxy-acme | 2022/09/13 10:50:34 Generated '/etc/nginx/conf.d/default.conf' from 16 containers
nginx-proxy-acme | 2022/09/13 10:50:34 [notice] 93#93: signal process started
nginx-proxy-acme | Creating/renewal deluge.streamz.co.za certificates... (example.com)
nginx-proxy-acme | 2022/09/13 08:50:35 Received event die for container 76d7ef0afd07
nginx-proxy-acme | 2022/09/13 08:50:36 Received event stop for container 76d7ef0afd07
nginx-proxy-acme | [Tue Sep 13 08:50:36 UTC 2022] Using CA: https://acme-v02.api.letsencrypt.org/directory
nginx-proxy-acme | [Tue Sep 13 08:50:37 UTC 2022] Creating domain key
nginx-proxy-acme | 2022/09/13 08:50:38 Received event start for container 4ab677ebd9c0
nginx-proxy-acme | [Tue Sep 13 08:50:42 UTC 2022] The domain key is here: /etc/acme.sh/[email protected]/example.com/example.com.key
nginx-proxy-acme | [Tue Sep 13 08:50:42 UTC 2022] Single domain='example.com'
nginx-proxy-acme | [Tue Sep 13 08:50:42 UTC 2022] Getting domain auth token for each domain
nginx-proxy-acme | 2022/09/13 08:50:43 Debounce minTimer fired
nginx-proxy-acme | 2022/09/13 08:50:44 Contents of /app/letsencrypt_service_data did not change. Skipping notification '/app/signal_le_service'
nginx-proxy-acme | [Tue Sep 13 08:50:47 UTC 2022] Getting webroot for domain='example.com'
nginx-proxy-acme | [Tue Sep 13 08:50:47 UTC 2022] Verifying: example.com
nginx-proxy-acme | [Tue Sep 13 08:50:52 UTC 2022] Success
nginx-proxy-acme | [Tue Sep 13 08:50:52 UTC 2022] Verify finished, start to sign.
nginx-proxy-acme | [Tue Sep 13 08:50:52 UTC 2022] Lets finalize the order.
nginx-proxy-acme | [Tue Sep 13 08:50:52 UTC 2022] Le_OrderFinalize='https://acme-v02.api.letsencrypt.org/acme/finalize/124991341/125647874517'
nginx-proxy-acme | [Tue Sep 13 08:50:54 UTC 2022] Downloading cert.
nginx-proxy-acme | [Tue Sep 13 08:50:54 UTC 2022] Le_LinkCert='https://acme-v02.api.letsencrypt.org/acme/cert/033d14714941b646bb17f5a94678b7269825'
nginx-proxy-acme | [Tue Sep 13 08:50:55 UTC 2022] Cert success.
Metadata
Metadata
Assignees
Labels
No labels