1. Caddy version (caddy version
):
v2.3.0
2. How I run Caddy:
a. System environment:
Debian 10.
b. Command:
From user (not root):
sudo caddy start
d. My complete Caddyfile or JSON config:
3. The problem I’m having:
EDIT: I resolved the installation problem. I have a different problem now.
EDIT 2: sorry, I am editing again as the service seems to be running for now.
I installed Caddy on Debian 10 using the instructions found here: https://caddyserver.com/docs/install
Now this is all new to me, it’s the first time I play with a server, I am only trying to get a simple static website to work.
4. Error messages and/or full log output:
2021/04/30 16:56:09.279 INFO using adjacent Caddyfile
2021/04/30 16:56:09.280 INFO admin admin endpoint started {"address": "tcp/0.0.0.0:2021", "enforce_origin": false, "origins": ["0.0.0.0:2021"]}
2021/04/30 16:56:09.280 WARN admin admin endpoint on open interface; host checking disabled {"address": "tcp/0.0.0.0:2021"}
2021/04/30 16:56:09.281 INFO http server is listening only on the HTTPS port but has no TLS connection policies; adding one to enable TLS {"server_name": "srv0", "https_port": 443}
2021/04/30 16:56:09.281 INFO http enabling automatic HTTP->HTTPS redirects {"server_name": "srv0"}
run: loading initial config: loading new config: http app module: start: tcp: listening on :443: listen tcp :443: bind: address already in use
start: caddy process exited with error: exit status 1
5. What I already tried:
So I had a problem with the service that I resolved by adding to my Caddyfile:
{
admin 0.0.0.0:2020
}
This allowed the service to run fine, but when I do sudo caddy start
I get an error on 2020
, so I changed to:
{
admin 0.0.0.0:2021
}
Now I get a new error as above, ie 443 already in use.
This is the output of sudo netstat -tulpn | grep 443
:
tcp6 0 0 :::443 :::* LISTEN 4326/caddy
Output of ps aux | grep caddy
:
caddy 4326 0.0 1.9 736344 38852 ? Ssl 18:51 0:00 /usr/bin/caddy run --environ --config /etc/caddy/Caddyfile
Now I am truly stuck.
Sorry for the many edits. I feel like I am digging my grave deeper. Is there a clean solution to this mess?
Please be kind, I’m a real noob! Any help would be greatly appreciated.