blog: Zola site, nginx image, Forgejo deploy pipeline
All checks were successful
Build and Deploy to Production / check (push) Successful in 9s
Build and Deploy to Production / build (push) Successful in 25s
Build and Deploy to Production / deploy (push) Successful in 36s

This commit is contained in:
Sergei Poljanski 2026-07-16 19:51:31 +04:00
commit a4b677f898
Signed by: asxpi
GPG key ID: 4F8851660FA4121B
23 changed files with 561 additions and 0 deletions

21
CLAUDE.md Normal file
View file

@ -0,0 +1,21 @@
# blog.asxp.io — static blog
Zola static site, built in CI into an nginx container, served behind Traefik on the same prod host as asxp.io. Mirrors the conventions of the sibling `../asxpio` repo (Kaniko build, SSH compose deploy, health-wait); see that repo's CLAUDE.md for the pipeline details.
## Writing a post
Add `content/<slug>.md` with TOML front matter (`title`, `date`, optional `description`), push to `main`. CI rebuilds and deploys. Local preview: `nix develop -c zola serve` → http://127.0.0.1:1111.
## Stack
- **Zola** — version pinned in `Dockerfile` (`ghcr.io/getzola/zola`, no `:latest` tag exists); the `flake.nix` dev shell tracks nixpkgs independently. Bump the Dockerfile pin manually.
- Multi-stage `Dockerfile`: `zola build``nginx:alpine` serving the generated `public/`. nginx config in `nginx.conf` (404 page + short static cache).
- `docker-compose.yml`: Traefik labels for `blog.asxp.io`, joins only the external `traefik` network — no storage-stack dependency, fully static, no `.env`.
- Deploy dir on prod: `/opt/blog`. Secrets used (shared with asxpio): `DEPLOY_IP/USER/SSH_KEY`, `FORGEJO_REGISTRY/USER/TOKEN`. Nothing else.
- `templates/` are hand-written Tera (no theme); `static/style.css` reuses the asxp.io dark palette (`#121212` bg, Open Sans + Hack).
## Rules
- Same hard rule as the main site: **never use the words "consulting" or "advisory"** in posts or copy — "services", "engineering", "implementation" instead.
- Blog content is fully public; no entity details beyond what asxp.io already shows (no banking, no registration number).
- Atom feed at `/atom.xml` (`generate_feeds = true` in `config.toml`).