- Go 59.8%
- Go Template 19%
- templ 14.3%
- Shell 2.4%
- HCL 1.5%
- Other 3%
| .forgejo/workflows | ||
| .github | ||
| deploy | ||
| docs | ||
| infra | ||
| pkg | ||
| services | ||
| .dockerignore | ||
| .env.example | ||
| .gitattributes | ||
| .gitignore | ||
| .pre-commit-config.yaml | ||
| docker-compose.micro.yml | ||
| docker-compose.obs.yml | ||
| go.mod | ||
| go.sum | ||
| go.work | ||
| go.work.sum | ||
| Makefile.port | ||
| README.md | ||
| SECURITY.md | ||
| VPS_PROVIDERS.md | ||
ARTEX-NG
Reimplementation of artex-global as independent microservices. Every service is a Go module with the same shape:
services/<name>/
domain/ pure types, rules and state machines (stdlib only)
ports/ interfaces the domain needs
app/ use cases, depending only on domain + ports
adapters/ NATS, Postgres, Redis, S3, HTTP, provider APIs
cmd/ composition root
Adapters point inward; the domain never imports an adapter. Contracts live in
pkg/contracts (versioned artex.v1.*), platform plumbing in pkg/platform.
Services
| Service | Responsibility | In | Out |
|---|---|---|---|
| gateway | edge, request IDs, Redis rate limit, reverse proxy | HTTP | api |
| api | REST + templ/htmx UI, auth cookie | HTTP | NATS commands/queries |
| chatter | per-task chat, Telegram topic bridge, announcements | Telegram, NATS chat/events | chat store, LLM, NATS commands |
| orchestrator | task/intent state machine, durable dispatch | NATS commands | JetStream work |
| worker | one intent per job, LLM loop + bash sandbox | JetStream work | results/activity |
| llm-gateway | provider keys, streaming, failover, usage | HTTP/SSE + NATS request/reply | provider APIs |
| traffic | MITM recorder, query API, bodies in S3 | target traffic | Postgres index + S3 |
| catalog | read model for tasks/assets/findings | NATS queries | Postgres (+Redis cache) |
| notifier | finding fan-out, retry ladder, channels | JetStream events | webhooks |
| reporter | report/export artifacts | JetStream report jobs | S3 |
Postgres owns metadata, JetStream owns hand-off and fan-out, Redis owns ephemeral state (rate limits, locks, cache), S3 owns bodies/artifacts.
Local development
make -f Makefile.port tidy
make -f Makefile.port verify # build + vet + unit tests
make -f Makefile.port build # binaries in bin/
A local topology is in docker-compose.micro.yml (Postgres, NATS, Redis, MinIO).
Add docker-compose.obs.yml for Loki, Tempo and Grafana; see
docs/observability.md.
CI/CD
Woodpecker (.woodpecker.yml) runs on every push to main: verify, build and
push every image to the in-cluster Zot registry keyed by commit SHA, then
helm upgrade the release in artex-apps. It never relies on a developer
pushing images by hand.
Required repo secret: kubeconfig.
Kubernetes
infra/helm/artexng deploys the services plus Postgres, Redis, NATS and MinIO,
with PDB-less single-replica stateful stores (fine for the current node pool),
default-deny networking and one ingress.
helm upgrade --install artexng infra/helm/artexng -n artex-apps --create-namespace
The API asks for ADMIN_PASSWORD (generated by Helm) at /login.
Upstream
No import path references github.com/Autumn-27/artex; the old monolith is
gone. Behaviour was reimplemented against the contracts, not vendored.