1. The problem I’m having:
I have a custom domain, doronkatz.cloud, Tailscale installed (on my Mac via homebrew), and caddy (installed via homebrew). All on the latest public release.
I want to be able to have Tailscale VPN enabled, and go to my domain via my browser and have it go to a web-app I have exposed in port :3000 on my Mac mini via Tailscale. Unfortunately I am not getting anywhere. On my browser it doesn’t return a valid page.
I believe my domain registrar settings may also be an issue. My settings are:
2. Error messages and/or full log output:
I run the following command:
❯ sudo caddy run --config Caddyfile
I get the following (in debug mode. I use a Mac so I don’t have journalctl):
2025/01/01 01:38:49.019 INFO using config from file {"file": "Caddyfile"}
2025/01/01 01:38:49.020 INFO adapted config to JSON {"adapter": "caddyfile"}
2025/01/01 01:38:49.023 INFO admin admin endpoint started {"address": "localhost:2019", "enforce_origin": false, "origins": ["//localhost:2019", "//[::1]:2019", "//127.0.0.1:2019"]}
2025/01/01 01:38:49.023 INFO http.auto_https 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}
2025/01/01 01:38:49.023 INFO http.auto_https enabling automatic HTTP->HTTPS redirects {"server_name": "srv0"}
2025/01/01 01:38:49.023 INFO tls.cache.maintenance started background certificate maintenance {"cache": "0x14000294980"}
2025/01/01 01:38:49.023 DEBUG http.auto_https adjusted config {"tls": {"automation":{"policies":[{}]}}, "http": {"servers":{"remaining_auto_https_redirects":{"listen":[":80"],"routes":[{},{}]},"srv0":{"listen":[":443"],"routes":[{"handle":[{"handler":"subroute","routes":[{"handle":[{"handler":"reverse_proxy","upstreams":[{"dial":"localhost:3000"}]}]}]}],"terminal":true}],"tls_connection_policies":[{}],"automatic_https":{}}}}}
2025/01/01 01:38:49.024 INFO http enabling HTTP/3 listener {"addr": ":443"}
2025/01/01 01:38:49.024 DEBUG http starting server loop {"address": "[::]:443", "tls": true, "http3": true}
2025/01/01 01:38:49.024 INFO http.log server running {"name": "srv0", "protocols": ["h1", "h2", "h3"]}
2025/01/01 01:38:49.024 DEBUG http starting server loop {"address": "[::]:80", "tls": false, "http3": false}
2025/01/01 01:38:49.024 INFO http.log server running {"name": "remaining_auto_https_redirects", "protocols": ["h1", "h2", "h3"]}
2025/01/01 01:38:49.024 INFO http enabling automatic TLS certificate management {"domains": ["doronkatz.cloud"]}
2025/01/01 01:38:49.025 INFO autosaved config (load with --resume flag) {"file": "/Users/doronkatz/Library/Application Support/Caddy/autosave.json"}
2025/01/01 01:38:49.025 INFO serving initial configuration
2025/01/01 01:38:49.025 INFO tls.obtain acquiring lock {"identifier": "doronkatz.cloud"}
2025/01/01 01:38:49.029 INFO tls storage cleaning happened too recently; skipping for now {"storage": "FileStorage:/Users/doronkatz/Library/Application Support/Caddy", "instance": "ecf8d249-7c91-4e90-8d07-468f58c512e5", "try_again": "2025/01/02 01:38:49.029", "try_again_in": 86399.9999995}
2025/01/01 01:38:49.031 INFO tls finished cleaning storage units
2025/01/01 01:38:49.035 INFO tls.obtain lock acquired {"identifier": "doronkatz.cloud"}
2025/01/01 01:38:49.035 INFO tls.obtain obtaining certificate {"identifier": "doronkatz.cloud"}
2025/01/01 01:38:49.035 DEBUG events event {"name": "cert_obtaining", "id": "269f9dc1-20a2-4455-88fe-c5b57b8d716d", "origin": "tls", "data": {"identifier":"doronkatz.cloud"}}
2025/01/01 01:38:49.035 DEBUG tls.obtain trying issuer 1/1 {"issuer": "acme-v02.api.letsencrypt.org-directory"}
2025/01/01 01:38:49.035 INFO http waiting on internal rate limiter {"identifiers": ["doronkatz.cloud"], "ca": "https://acme-v02.api.letsencrypt.org/directory", "account": ""}
2025/01/01 01:38:49.035 INFO http done waiting on internal rate limiter {"identifiers": ["doronkatz.cloud"], "ca": "https://acme-v02.api.letsencrypt.org/directory", "account": ""}
2025/01/01 01:38:49.035 INFO http using ACME account {"account_id": "https://acme-v02.api.letsencrypt.org/acme/acct/2138939525", "account_contact": []}
2025/01/01 01:38:49.261 DEBUG http.acme_client http request {"method": "GET", "url": "https://acme-v02.api.letsencrypt.org/directory", "headers": {"User-Agent":["Caddy/2.8.4 CertMagic acmez (darwin; arm64)"]}, "response_headers": {"Cache-Control":["public, max-age=0, no-cache"],"Content-Length":["746"],"Content-Type":["application/json"],"Date":["Wed, 01 Jan 2025 01:38:49 GMT"],"Server":["nginx"],"Strict-Transport-Security":["max-age=604800"],"X-Frame-Options":["DENY"]}, "status_code": 200}
2025/01/01 01:38:49.262 DEBUG http.acme_client creating order {"account": "https://acme-v02.api.letsencrypt.org/acme/acct/2138939525", "identifiers": ["doronkatz.cloud"]}
2025/01/01 01:38:49.334 DEBUG http.acme_client http request {"method": "HEAD", "url": "https://acme-v02.api.letsencrypt.org/acme/new-nonce", "headers": {"User-Agent":["Caddy/2.8.4 CertMagic acmez (darwin; arm64)"]}, "response_headers": {"Cache-Control":["public, max-age=0, no-cache"],"Date":["Wed, 01 Jan 2025 01:38:49 GMT"],"Link":["<https://acme-v02.api.letsencrypt.org/directory>;rel=\"index\""],"Replay-Nonce":["WVWTDxmJ7-o6jtgQvLCE2dfh6tR6ISc1ZJHFuERiuCWBbt9R_o8"],"Server":["nginx"],"Strict-Transport-Security":["max-age=604800"],"X-Frame-Options":["DENY"]}, "status_code": 200}
2025/01/01 01:38:49.582 DEBUG http.acme_client http request {"method": "POST", "url": "https://acme-v02.api.letsencrypt.org/acme/new-order", "headers": {"Content-Type":["application/jose+json"],"User-Agent":["Caddy/2.8.4 CertMagic acmez (darwin; arm64)"]}, "response_headers": {"Boulder-Requester":["2138939525"],"Cache-Control":["public, max-age=0, no-cache"],"Content-Length":["349"],"Content-Type":["application/json"],"Date":["Wed, 01 Jan 2025 01:38:49 GMT"],"Link":["<https://acme-v02.api.letsencrypt.org/directory>;rel=\"index\""],"Location":["https://acme-v02.api.letsencrypt.org/acme/order/2138939525/339421400585"],"Replay-Nonce":["WVWTDxmJSGwMZ7TQJH3MPWXMJEYJw2c6y-6KSbhgfG4KS1skMpE"],"Server":["nginx"],"Strict-Transport-Security":["max-age=604800"],"X-Frame-Options":["DENY"]}, "status_code": 201}
2025/01/01 01:38:49.667 DEBUG http.acme_client http request {"method": "POST", "url": "https://acme-v02.api.letsencrypt.org/acme/authz/2138939525/453643504645", "headers": {"Content-Type":["application/jose+json"],"User-Agent":["Caddy/2.8.4 CertMagic acmez (darwin; arm64)"]}, "response_headers": {"Boulder-Requester":["2138939525"],"Cache-Control":["public, max-age=0, no-cache"],"Content-Length":["823"],"Content-Type":["application/json"],"Date":["Wed, 01 Jan 2025 01:38:49 GMT"],"Link":["<https://acme-v02.api.letsencrypt.org/directory>;rel=\"index\""],"Replay-Nonce":["WVWTDxmJHuJTW67hFr2lAhyc4ImOW5wdkkpLbQ60Go0aF2a-zCY"],"Server":["nginx"],"Strict-Transport-Security":["max-age=604800"],"X-Frame-Options":["DENY"]}, "status_code": 200}
2025/01/01 01:38:49.668 DEBUG http.acme_client no solver configured {"challenge_type": "dns-01"}
2025/01/01 01:38:49.668 INFO http.acme_client trying to solve challenge {"identifier": "doronkatz.cloud", "challenge_type": "http-01", "ca": "https://acme-v02.api.letsencrypt.org/directory"}
2025/01/01 01:38:49.669 DEBUG http.acme_client waiting for solver before continuing {"identifier": "doronkatz.cloud", "challenge_type": "http-01"}
2025/01/01 01:38:49.669 DEBUG http.acme_client done waiting for solver {"identifier": "doronkatz.cloud", "challenge_type": "http-01"}
2025/01/01 01:38:49.779 DEBUG http.acme_client http request {"method": "POST", "url": "https://acme-v02.api.letsencrypt.org/acme/chall/2138939525/453643504645/uzYkUQ", "headers": {"Content-Type":["application/jose+json"],"User-Agent":["Caddy/2.8.4 CertMagic acmez (darwin; arm64)"]}, "response_headers": {"Boulder-Requester":["2138939525"],"Cache-Control":["public, max-age=0, no-cache"],"Content-Length":["195"],"Content-Type":["application/json"],"Date":["Wed, 01 Jan 2025 01:38:49 GMT"],"Link":["<https://acme-v02.api.letsencrypt.org/directory>;rel=\"index\"","<https://acme-v02.api.letsencrypt.org/acme/authz/2138939525/453643504645>;rel=\"up\""],"Location":["https://acme-v02.api.letsencrypt.org/acme/chall/2138939525/453643504645/uzYkUQ"],"Replay-Nonce":["WVWTDxmJsq-3cqLbfxuiZMYiryXObMmg-rhRwFJE8x-xyg_qw4s"],"Server":["nginx"],"Strict-Transport-Security":["max-age=604800"],"X-Frame-Options":["DENY"]}, "status_code": 200}
letsencrypt.org/acme/authz/2138939525/453643504645", "headers": {"Content-Type":["application/jose+json"],"User-Agent":["Caddy/2.8.4 CertMagic acmez (darwin; arm64)"]}, "response_headers": {"Boulder-Requester":["2138939525"],"Cache-Control":["public, max-age=0, no-cache"],"Content-Length":["634"],"Content-Type":["application/json"],"Date":["Wed, 01 Jan 2025 01:38:50 GMT"],"Link":["<https://acme-v02.api.letsencrypt.org/directory>;rel=\"index\""],"Replay-Nonce":["GJdccAF6i7Fdm0bfo4z1_3Y4qyTusIMaJQZ16MV-HhFxNo71kaE"],"Server":["nginx"],"Strict-Transport-Security":["max-age=604800"],"X-Frame-Options":["DENY"]}, "status_code": 200}
2025/01/01 01:38:50.115 ERROR http.acme_client challenge failed {"identifier": "doronkatz.cloud", "challenge_type": "http-01", "problem": {"type": "urn:ietf:params:acme:error:dns", "title": "", "detail": "no valid A records found for doronkatz.cloud; no valid AAAA records found for doronkatz.cloud", "instance": "", "subproblems": []}}
2025/01/01 01:38:50.115 ERROR http.acme_client validating authorization {"identifier": "doronkatz.cloud", "problem": {"type": "urn:ietf:params:acme:error:dns", "title": "", "detail": "no valid A records found for doronkatz.cloud; no valid AAAA records found for doronkatz.cloud", "instance": "", "subproblems": []}, "order": "https://acme-v02.api.letsencrypt.org/acme/order/2138939525/339421400585", "attempt": 1, "max_attempts": 3}
2025/01/01 01:38:51.116 DEBUG http.acme_client creating order {"account": "https://acme-v02.api.letsencrypt.org/acme/acct/2138939525", "identifiers": ["doronkatz.cloud"]}
2025/01/01 01:38:51.428 DEBUG http.acme_client http request {"method": "POST", "url": "https://acme-v02.api.letsencrypt.org/acme/new-order", "headers": {"Content-Type":["application/jose+json"],"User-Agent":["Caddy/2.8.4 CertMagic acmez (darwin; arm64)"]}, "response_headers": {"Boulder-Requester":["2138939525"],"Cache-Control":["public, max-age=0, no-cache"],"Content-Length":["349"],"Content-Type":["application/json"],"Date":["Wed, 01 Jan 2025 01:38:51 GMT"],"Link":["<https://acme-v02.api.letsencrypt.org/directory>;rel=\"index\""],"Location":["https://acme-v02.api.letsencrypt.org/acme/order/2138939525/339421407485"],"Replay-Nonce":["WVWTDxmJwHsvlXg3rfj_Xg-TGrHvi0SiE8MsmJjOBlCInse6tiE"],"Server":["nginx"],"Strict-Transport-Security":["max-age=604800"],"X-Frame-Options":["DENY"]}, "status_code": 201}
2025/01/01 01:38:51.521 DEBUG http.acme_client http request {"method": "POST", "url": "https://acme-v02.api.letsencrypt.org/acme/authz/2138939525/453643514245", "headers": {"Content-Type":["application/jose+json"],"User-Agent":["Caddy/2.8.4 CertMagic acmez (darwin; arm64)"]}, "response_headers": {"Boulder-Requester":["2138939525"],"Cache-Control":["public, max-age=0, no-cache"],"Content-Length":["823"],"Content-Type":["application/json"],"Date":["Wed, 01 Jan 2025 01:38:51 GMT"],"Link":["<https://acme-v02.api.letsencrypt.org/directory>;rel=\"index\""],"Replay-Nonce":["GJdccAF6GlNLBgJ0VkCwEBHCdkMOJeKjb7r3woe0oDrw-CSQ0nU"],"Server":["nginx"],"Strict-Transport-Security":["max-age=604800"],"X-Frame-Options":["DENY"]}, "status_code": 200}
…
2025/01/01 01:38:51.961 ERROR http.acme_client challenge failed {"identifier": "doronkatz.cloud", "challenge_type": "tls-alpn-01", "problem": {"type": "urn:ietf:params:acme:error:dns", "title": "", "detail": "no valid A records found for doronkatz.cloud; no valid AAAA records found for doronkatz.cloud", "instance": "", "subproblems": []}}
2025/01/01 01:38:51.961 ERROR http.acme_client validating authorization {"identifier": "doronkatz.cloud", "problem": {"type": "urn:ietf:params:acme:error:dns", "title": "", "detail": "no valid A records found for doronkatz.cloud; no valid AAAA records found for doronkatz.cloud", "instance": "", "subproblems": []}, "order": "https://acme-v02.api.letsencrypt.org/acme/order/2138939525/339421407485", "attempt": 2, "max_attempts": 3}
2025/01/01 01:38:51.961 ERROR tls.obtain could not get certificate from issuer {"identifier": "doronkatz.cloud", "issuer": "acme-v02.api.letsencrypt.org-directory", "error": "HTTP 400 urn:ietf:params:acme:error:dns - no valid A records found for doronkatz.cloud; no valid AAAA records found for doronkatz.cloud"}
2025/01/01 01:38:51.961 DEBUG events event {"name": "cert_failed", "id": "217d6299-f7e6-4bc1-b2f9-0f9de199a192", "origin": "tls", "data": {"error":{},"identifier":"doronkatz.cloud","issuers":["acme-v02.api.letsencrypt.org-directory"],"renewal":false}}
2025/01/01 01:38:51.961 ERROR tls.obtain will retry {"error": "[doronkatz.cloud] Obtain: [doronkatz.cloud] solving challenge: doronkatz.cloud: [doronkatz.cloud] authorization failed: HTTP 400 urn:ietf:params:acme:error:dns - no valid A records found for doronkatz.cloud; no valid AAAA records found for doronkatz.cloud (ca=https://acme-v02.api.letsencrypt.org/directory)", "attempt": 1, "retrying_in": 60, "elapsed": 2.926925792, "max_duration": 2592000}
^C2025/01/01 01:39:36.318 INFO shutting down {"signal": "SIGINT"}
2025/01/01 01:39:36.318 WARN exiting; byeee!! 👋 {"signal": "SIGINT"}
2025/01/01 01:39:36.318 INFO http servers shutting down with eternal grace period
2025/01/01 01:39:36.319 INFO tls.obtain releasing lock {"identifier": "doronkatz.cloud"}
2025/01/01 01:39:36.319 ERROR tls.obtain unable to unlock {"identifier": "doronkatz.cloud", "lock_key": "issue_cert_doronkatz.cloud", "error": "remove /Users/doronkatz/Library/Application Support/Caddy/locks/issue_cert_doronkatz.cloud.lock: no such file or directory"}
2025/01/01 01:39:36.319 INFO admin stopped previous server {"address": "localhost:2019"}
2025/01/01 01:39:36.319 INFO shutdown complete {"signal": "SIGINT", "exit_code": 0}
3. Caddy version:
v2.8.4 h1:q3pe0wpBj1OcHFZ3n/1nl4V4bxBrYoSoab7rL9BMYNk=
4. How I installed and ran Caddy:
brew install caddy
a. System environment:
❯ sw_vers
ProductName: macOS
ProductVersion: 15.3
BuildVersion: 24D5034f
b. Command:
❯ sudo caddy run --config Caddyfile
d. My complete Caddy config:
❯ cat Caddyfile
{
debug
}
doronkatz.cloud {
reverse_proxy localhost:3000
}