强曰为道
与天地相似,故不违。知周乎万物,而道济天下,故不过。旁行而不流,乐天知命,故不忧.
文档目录

Caddy 从入门到精通

Caddy 从入门到精通 / Caddy: From Beginner to Expert

一套由浅入深的 Caddy Web Server 完整教程。 A comprehensive Caddy Web Server tutorial, from shallow to deep.


目录 / Table of Contents

#章节 / Chapter关键词 / Keywords
1初识 Caddy / Introduction to CaddyWhat, Why, Philosophy
2安装与部署 / Installation & DeploymentInstall, Build, Systemd
3静态文件服务 / Static File Servingfile_server, browse, templates
4反向代理 / Reverse Proxyreverse_proxy, upstream, LB
5TLS 与 HTTPS / TLS & HTTPSACME, Let’s Encrypt, OCSP
6路由与匹配 / Routing & Matchingmatch, handle, route
7中间件 / Middlewareencode, basicauth, rate_limit
8API 与动态配置 / API & Dynamic ConfigREST API, adapt, reload
9Docker 部署 / Docker DeploymentDockerfile, Compose, volumes
10高级主题 / Advanced TopicsCluster, Metrics, Plugins

阅读建议 / How to Read

  • 初学者 / Beginners: 从第 1 章开始,按顺序阅读 / Start from Chapter 1, read in order.
  • 有经验者 / Experienced: 直接跳到感兴趣的章节 / Jump to the chapter you need.
  • 查阅用途 / Reference: 每章独立成文,可按需查阅 / Each chapter is self-contained.

每章结构:

  • 🟢 基础 — 最简单的用法 / Basic — simplest usage
  • 🟡 进阶 — 生产环境常见配置 / Intermediate — production-ready
  • 🔴 高级 — 深入原理与极限用法 / Advanced — internals & edge cases