1. The problem I’m having:
Unable to run caddy.service, “systemctl status caddy” shows an error as follows:
“Error during parsing: getting module named ‘dns.providers.duckdns’: module not registered: dns.providers.duckdns”
2. Error messages and/or full log output:
> Jul 06 10:08:30 raspberrypi caddy[16346]: LANG=en_DK
> Jul 06 10:08:30 raspberrypi caddy[16346]: LANGUAGE=en_DK
> Jul 06 10:08:30 raspberrypi caddy[16346]: PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin
> Jul 06 10:08:30 raspberrypi caddy[16346]: NOTIFY_SOCKET=/run/systemd/notify
> Jul 06 10:08:30 raspberrypi caddy[16346]: HOME=/var/lib/caddy
> Jul 06 10:08:30 raspberrypi caddy[16346]: LOGNAME=caddy
> Jul 06 10:08:30 raspberrypi caddy[16346]: USER=caddy
> Jul 06 10:08:30 raspberrypi caddy[16346]: INVOCATION_ID=6528405368494e6f83c52988a98dbaa6
> Jul 06 10:08:30 raspberrypi caddy[16346]: JOURNAL_STREAM=8:65948
> Jul 06 10:08:30 raspberrypi caddy[16346]: {"level":"info","ts":1688630910.8086872,"msg":"using provided configuration","config_file":"/etc/caddy/Caddyfile","config_adapter":""}
> Jul 06 10:08:30 raspberrypi caddy[16346]: Error: adapting config using caddyfile: parsing caddyfile tokens for 'tls': /etc/caddy/Caddyfile:4 - Error during parsing: getting module named 'dns.providers.duckdns': module not registered: dns.providers.duckdns
> Jul 06 10:08:30 raspberrypi systemd[1]: caddy.service: Main process exited, code=exited, status=1/FAILURE
> Jul 06 10:08:30 raspberrypi systemd[1]: caddy.service: Failed with result 'exit-code'.
> Jul 06 10:08:30 raspberrypi systemd[1]: Failed to start Caddy.
3. Caddy version:
v2.6.4 h1:2hwYqiRwk1tf3VruhMpLcYTg+11fCdr8S3jhNAdnPy8=
4. How I installed and ran Caddy:
First I installed Caddy, as per usual
sudo apt install -y debian-keyring debian-archive-keyring apt-transport-https
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/gpg.key' | sudo gpg --dearmor -o /usr/share/keyrings/caddy-stable-archive-keyring.gpg
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/debian.deb.txt' | sudo tee /etc/apt/sources.list.d/caddy-stable.list
sudo apt update
sudo apt install caddy
Then I fetched the Duck DNS module with xcaddy, after fumbling to get Go to work for a couple of hours…
xcaddy build --with https://github.com/caddy-dns/duckdns
I attempted to do the update-alternative procedure, without luck.
Running ‘systemctl start caddy’ gives the error shown in the start.
a. System environment:
Raspberry Pi 4 Model B, with Raspbian newest version.
b. Command:
systemctl start caddy
c. Service/unit/compose file:
d. My complete Caddy config:
jellyfinlynge12.duckdns.org {
reverse_proxy 192.168.0.204:8096
tls {
dns duckdns (my token)
}
}
I have tried several re-arrangements, without further luck. This is just the most recent I attempted, with inspiration from DemonWarriorTech’s YouTube video
5. Links to relevant resources:
n/a