WIUNIX ACADEMY
Set up Traefik with Let’s Encrypt and HTTP/3 on Linux
Page 5 of 7. Review the earlier steps and prerequisites before continuing.
YOUR SYSTEM. YOUR STEPS.
Where are you working?
Choose your OS and version. The prerequisites, commands and troubleshooting follow your environment.
USE YOUR OWN VALUES
Configure this tutorial
Set the example values for your environment; related explanations and copy panels update together. Never enter passwords, private keys or tokens. Values stay in this tab and are not sent to the server or share links. Check actual DNS, certificates and network policy before running commands.
Different IP addresses, domains or ports? Open the settings below, change the values and select “Apply to tutorial”, then copy the updated commands.
Set values for my environment11 editable values
LET’S BUILD
Independent trusted-certificate checks
Run on a Linux client with current CA roots. Require exact marker text and Verify return code: 0 (ok), correct hostname/SAN and production issuer. A 200 response with a bypassed trust check is insufficient. If your client has no HTTP/2 support, use the basic trusted request first and a capable client for protocol verification.
Independent external Linux client
curl --fail --silent --show-error --noproxy '*' 'https://app.example.com/health.txt'
openssl s_client -connect 'app.example.com:443' -servername 'app.example.com' -verify_hostname 'app.example.com' -verify_return_error </dev/null
curl --version
curl --http2 --fail --silent --show-error --noproxy '*' --output /dev/null --write-out 'HTTP version: %{http_version}\n' 'https://app.example.com/health.txt'
Trusted marker response, zero certificate verification error, HTTP/2 negotiated on a capable client.
LET’S BUILD
Prove HTTP/3 rather than only Alt-Svc
HTTP/3 requires a client with HTTP3 in curl’s Features output and an end-to-end UDP/443 path. The stock curl of a selected OS may lack that feature; no unsupported package replacement is required here. Use an existing approved HTTP/3-capable client or browser network inspector reporting h3. Alt-Svc only advertises availability and is not proof a QUIC request succeeded. --http3-only forbids an unnoticed fallback; the final request separately verifies the TCP path. Do not disable certificate validation to make it work.
Independent HTTP/3-capable client
curl --version
curl --silent --show-error --head --noproxy '*' 'https://app.example.com/health.txt'
curl --http3-only --fail --silent --show-error --noproxy '*' --write-out '
HTTP version: %{http_version}
' 'https://app.example.com/health.txt'
curl --http1.1 --fail --silent --show-error --noproxy '*' 'https://app.example.com/health.txt'
Capable client receives the exact marker with HTTP version 3; trusted TCP request still succeeds.
LET’S BUILD
Use the dashboard through an SSH tunnel
Run the tunnel on your own workstation using your existing verified SSH identity and host key. It binds only local 127.0.0.1:8080; choose a free local port, or update the admin-port setting consistently. Keep the terminal open, then visit the local dashboard URL including its trailing slash in your browser. The API is available only to this host and authorized tunnel users; other local users/processes on the server can also reach loopback, so the host itself must be trusted. Do not publish this endpoint or enable api.insecure.
Your workstation terminal and browser
ssh -p 22 -N -o ExitOnForwardFailure=yes -L 127.0.0.1:8080:127.0.0.1:8080 admin@203.0.113.10
Tunnel listens only on local loopback; dashboard route and app@file show enabled.
Check private and public API boundaries
With the tunnel open, the first two local requests run on your workstation. Open http://127.0.0.1:8080/dashboard/ there. Inspect route status without sharing the API response or operational details. The last HTTPS request targets the public app: it must not return Traefik API JSON. With this harmless file origin it returns 404. For a real app, distinguish its own /api path from Traefik API; a generic 200/404 alone is not enough.
curl --fail --silent --show-error --noproxy '*' 'http://127.0.0.1:8080/api/http/routers'
curl --silent --show-error --head --noproxy '*' 'http://127.0.0.1:8080/dashboard/'
curl --silent --show-error --noproxy '*' --output /dev/null --write-out 'Public API path status: %{http_code}\n' 'https://app.example.com/api/http/routers'
LET’S BUILD
Monitor renewal, expiry and state
Traefik renews certificates internally; do not add Certbot or a second writer to its ACME file. Current defaults track a 90-day duration and begin renewal 30 days before expiry; CA profiles/lifetimes are changing, so monitor actual notAfter, issuance errors and current resolver guidance. Keep HTTP-01 port 80 reachable and state persistent/writable at 0600. Monitor from outside for trusted TLS, expected body and remaining lifetime, with an actionable alert well before your organization’s recovery deadline. This guide has not waited for a real public renewal and does not claim one.
Dedicated Linux host
sudo stat -c '%a %U:%G %n' '/var/lib/traefik-academy' '/var/lib/traefik-academy/acme-production.json'
sudo journalctl -u traefik-academy.service --since '24 hours ago' --no-pager
bash -o pipefail <<'CERT'
openssl s_client -connect 'app.example.com:443' -servername 'app.example.com' -verify_hostname 'app.example.com' -verify_return_error </dev/null 2>/dev/null | openssl x509 -noout -issuer -dates -checkend 1209600
CERT
Protected state, no renewal errors; external certificate expires later than the example 14-day alert threshold.
Certificate failure: DNS, reachability or permissions
First inspect the exact ACME error. Wrong A/AAAA, restrictive CAA, blocked inbound TCP80, another listener, wrong clock or unwritable state are distinct causes. Correct that cause and allow the next normal attempt; respect the CA retry time. Do not erase ACME state or repeatedly restart against production. The probes below are host diagnostics; repeat public DNS/HTTP checks from outside as well.
dig A app.example.com
dig AAAA app.example.com
dig CAA app.example.com
timedatectl status
sudo ss -lntp 'sport = :80'
sudo -u traefik-academy test -w '/var/lib/traefik-academy/acme-production.json'
sudo journalctl -u traefik-academy.service --since '15 minutes ago' --no-pager