If you don’t already have an account, create one at https://www.duckdns.org/. Create a subdomain for your vaultwarden instance (e.g., my-vw.duckdns.org ), setting its IP to your vaultwarden host’s private IP (e.g., 192.168.1.100 ). Make note of your account’s token (a string in UUID format). Caddy will need this token to solve the DNS challenge.
vaultwarden.foo.com {
# The negotiation endpoint is also proxied to Rocket
reverse_proxy /notifications/hub/negotiate 192.168.11.74:8088
# Notifications redirected to the websockets server
reverse_proxy /notifications/hub 192.168.11.74:3012
# Proxy the Root directory to Rocket
reverse_proxy 192.168.11.74:8088
header {
# Enable cross-site filter (XSS) and tell browser to block detected attacks
X-XSS-Protection "1; mode=block"
# Disallow the site to be rendered within a frame (clickjacking protection)
X-Frame-Options "DENY"
# Prevent search engines from indexing (optional)
X-Robots-Tag "none"
# Server name removing
-Server
}
}