Custom Caddy with CrowdSec bouncer, AppSec and rate limiting
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
commit
f9c44868a4
5 files changed
+266
No files matched your search
@@ -0,0 +1,25 @@
|
||||
# caddy-custom
|
||||
|
||||
Caddy built with:
|
||||
|
||||
- [caddy-crowdsec-bouncer](https://github.com/hslatman/caddy-crowdsec-bouncer) (`http` + `appsec`)
|
||||
- [caddy-ratelimit](https://github.com/mholt/caddy-ratelimit)
|
||||
|
||||
Image: `git.thesatelliteoflove.com/phil/caddy`. Tags: `:2` (what the server runs),
|
||||
`:<caddy version>`, `:<caddy version>-<fingerprint>` (immutable, pin this to hold a build).
|
||||
|
||||
## How it stays current
|
||||
|
||||
`.gitea/workflows/build.yml` runs daily at 04:30. It fingerprints the Caddy version,
|
||||
the `caddy:<ver>-alpine` digest, the bouncer release, the caddy-ratelimit master commit
|
||||
and this repo's commit. If `:fp-<fingerprint>` already exists it stops; otherwise it
|
||||
builds, runs the test stage (modules present, fixture and the real production
|
||||
Caddyfile from `phil/ansible` validate) and pushes. Gotify (app "caddy-build") gets a
|
||||
message on success and a high-priority one on failure; a failed build pushes nothing.
|
||||
|
||||
On the server, dockcheck sees the new `:2` digest and recreates Caddy once the image
|
||||
is 3 days old (DaysOld). The ansible repo picks the image with `caddy_custom`.
|
||||
|
||||
Secrets: `REGISTRY_TOKEN` (PAT, write:package only), `GOTIFY_TOKEN`.
|
||||
|
||||
Manual rebuild: Actions → Build custom Caddy → Run workflow (tick *force*).
|
||||
Reference in new issue
Block a user