1. My Caddy version (caddy version
):
v2.0.0-rc.3 h1:z2H/QnaRscip6aZJxwTbghu3zhC88Vo8l/K57WUce4Q=
2. How I run Caddy:
a. System environment:
Running on CentOS 7 using systemd.
b. Command:
systemctl start caddy
c. Service/unit/compose file:
[Unit]
Description=Caddy
Documentation=https://caddyserver.com/docs/
After=network.target
[Service]
User=www-data
Group=www-data
ExecStart=/usr/bin/caddy run --environ --config /etc/caddy/Caddyfile
ExecReload=/usr/bin/caddy reload --config /etc/caddy/Caddyfile
TimeoutStopSec=5s
LimitNOFILE=1048576
LimitNPROC=512
PrivateTmp=true
ProtectSystem=full
AmbientCapabilities=CAP_NET_BIND_SERVICE
[Install]
WantedBy=multi-user.target
d. My complete Caddyfile or JSON config:
{
acme_ca https://acme-staging-v02.api.letsencrypt.org/directory
storage file_system {
root /var/lib/caddy
}
}
example.org {
root * /var/www/public
file_server
encode zstd gzip
}
3. The problem I’m having:
It’s the first time I’m working with Caddy, and while my overall experience was really , I stumbled over one thing:
I set the storage root to /var/lib/caddy
expecting Caddy to store everything in this directory, including autosave.json
. That doesn’t seem to be the case though – while certificates etc. are stored in /var/lib/caddy
, autosave.json
is stored in $HOME/.config/caddy
.
Just wanted to check wether this actually is the expected behavior. If so, I think clarifying this (e.g. here and/or here) might help – even though the docs are probably accurate if you read carefully. Happy to send a PR (if that’s the best way to propose changes to the docs?)
4. Error messages and/or full log output:
-/-
5. What I already tried:
-/-
6. Links to relevant resources:
-/-