Caddy is "a powerful, enterprise-ready, open source web server with automatic HTTPS written in Go"
- Setting up a reverse proxy using Caddy
- Setting up CORS in Caddy
- Making Caddy use a self-signed SSL certificate
- Enabling gzip/zstd compression in Caddy
handle
and handle_path
The handle
and handle_path
directives are similar. However, handle_path
will strip the path prefix from the request when matched.
handle_path /foo/* {
# The path has the "/foo" prefix stripped
}
handle /bar/* {
# The path still retains "/bar"
}
Further reading
redir
for redirects.reverse_proxy
for proxying requests to another server.