caddy
1
总安装量
1
周安装量
#48615
全站排名
安装命令
npx skills add https://github.com/g1joshi/agent-skills --skill caddy
Agent 安装分布
mcpjam
1
claude-code
1
replit
1
junie
1
zencoder
1
Skill 文档
Caddy
Caddy 2 is a powerful, enterprise-ready web server with automatic HTTPS by default. v2.8 (2025) improves HTTP/3 performance and certificate management.
When to Use
- HTTPS Default: You want zero-config SSL. Caddy obtains and renews certificates automatically.
- Simplicity:
Caddyfileis the most human-readable config format. - Go Apps: Can act as a process manager or library for Go applications.
Quick Start
# Caddyfile
example.com {
reverse_proxy localhost:3000
encode zstd gzip
file_server
}
Core Concepts
Caddyfile
Simple configuration format.
directive argument { block }
JSON Config
The native config format. Caddyfile is adapted to JSON. API allows real-time config updates via REST.
Modules
Caddy is extensible. Plugins (like caddy-dns-cloudflare) are compiled in via xcaddy.
Best Practices (2025)
Do:
- Use Caddyfile: For 99% of cases, it’s enough.
- Persist /data: Caddy stores certificates in the
/datadirectory. Mount this volume in Docker. - Use
caddy fmt: Auto-format your config.
Don’t:
- Don’t sit behind another proxy: If you hide Caddy behind Cloudflare/Nginx, you break its ACME challenges unless you configure it specifically.