1. Caddy version (
2. How I run Caddy:
Caddy configuration is load from JSON file using the curl endpoint.
a. System environment:
AWS EC2 (Ubuntu 20.04)
curl localhost:2019/load -H 'Content-Type: application/json' -d @final_with_headers.json
c. Service/unit/compose file:
paste full file contents here
d. My complete Caddyfile or JSON config:
paste config here, replacing this text use `caddy fmt` to make it readable DO NOT REDACT anything except credentials or helpers will be sad
3. The problem I’m having:
Many times, I need to stop-start the EC2 instance. Every time after the restart, the caddy configuration needs to be loaded manually by SSH to the server.
How can I auto-load the configuration file whenever the server is restarted. Just like other proxy providers (apache, nginx), their configuration can be saved inside
/etc/nginx/ directory, is there such a way in the Caddy?
Also planning to use auto-scaling to automatically provision new instances on load. Without auto loading, everything a new instance is launched, I need to manually load the configuration.