- Shell 62.9%
- Dockerfile 37.1%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
Jobs reach a docker:dind sidecar over DOCKER_HOST rather than a host Docker socket. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> |
||
| .forgejo/workflows | ||
| certs | ||
| test | ||
| Dockerfile | ||
| README.md | ||
hitoma-caddy
Caddy 2 with the route53 DNS and teapot plugins, trusting the Hitoma PKI v4 root CA.
docker pull forgejo.hitoma.com/root/hitoma-caddy:latest
Tests
Every build has to pass both of these before it's pushed:
- test/verify-image.sh, which needs no network:
- the binary has the route53 and teapot modules, and their Caddyfile directives parse
- the Hitoma root CA is in the system trust store
- test/smoke.sh, which runs Caddy with a test Caddyfile and checks it from a curl container:
- plain HTTP, the teapot handler (418) and
reverse_proxyall respond - HTTPS works with a certificate from Caddy's internal CA, verified against that CA's root
- the logs show no errors
- plain HTTP, the teapot handler (418) and
Both run locally too: test/verify-image.sh IMAGE, then test/smoke.sh IMAGE.
CI
.forgejo/workflows/build.yml builds on every push to main, weekly (Monday 06:17 UTC, without cache, to pick up base image and plugin updates), and on manual dispatch. Pull requests are built and tested but not pushed. Building, testing, scanning and pushing happen in the shared hitoma-image-ci pipeline.
If the build or a test fails, nothing is pushed, and latest stays on the last good image.
Tags: latest, YYYYMMDD, and sha-<short>.
Each build is scanned with Trivy after it passes the tests. Builds of main force-push the badge above and the full JSON report to the single-commit badges branch. The run fails when there are fixable HIGH or CRITICAL findings. The image is still pushed, but the red run shows that a base image or plugin update is needed. When a finding is in a Go dependency of Caddy or a plugin, add the module to BUMP_MODULES in the Dockerfile. It's forced to its latest version with an xcaddy --replace, and the build fails if the bump didn't make it into the binary.
Setup:
- Repository secrets
REGISTRY_USERandREGISTRY_TOKEN(a Forgejo access token withwrite:packagescope). - A Forgejo runner with the
dockerlabel whose job containers can reach a Docker daemon, such as adocker:dindsidecar throughDOCKER_HOST. - Actions enabled on the repository (Settings → Units → Actions).