3 homepage: https://github.com/caddyserver/caddy
5 Caddy is a fast, multi-platform web server with automatic HTTPS.
14 Use the `@beta` tag for pre-releases, or `@x.y.z` for a specific version.
18 > Caddy makes it easy to use Let's Encrypt to handle HTTPS (TLS/SSL) and to
19 > reverse proxy APIs and WebSockets to other apps - such as those written node,
20 > Go, python, ruby, and PHP.
22 ### How to serve a directory
25 caddy file-server --browse --listen :4040
28 ### How to redirect and reverse proxy
30 Here's what a fairly basic `Caddyfile` looks like:
33 # redirect www to bare domain
35 redir https://example.com{uri} permanent
39 # turn on standard streaming compression
42 # reverse proxy /api to :3000
43 reverse_proxy /api/* localhost:3000
45 # serve static files from public folder, but not /api
48 try_files {path} {path}/ /index.html
53 rewrite @notApi {http.matchers.file.relative}
55 root * /srv/example.com/public/
60 And here's how you run caddy with it:
63 caddy run --config ./Caddyfile