Upgrading from Option B to Option A
Step 1: Update Caddyfile
On the VM:
Replace hivel.yourcompany.com with your actual domain:
cat > ~/caddy/Caddyfile <<'EOF'
hivel.yourcompany.com {
reverse_proxy localhost:3000
}
EOFThis removes the tls internal directive, telling Caddy to use Let's Encrypt instead of a self-signed certificate.
Step 2: Restart Caddy
On the VM:
docker restart caddyCaddy detects the configuration change and automatically requests a trusted Let's Encrypt certificate on restart.
Step 3: Verify the Upgrade
Check Caddy logs for successful certificate issuance:
Look for: A line confirming certificate obtained successfully.
In your browser, navigate to:
Expected result: The page loads with a trusted certificate and no browser warning.
If it fails: See Certificate Not Issued in Troubleshooting.
Last updated