run attic as a swarm service with deploy.attic.enable
This commit is contained in:
parent
f59ed01353
commit
458a046b8d
1 changed files with 1242 additions and 66 deletions
|
|
@ -433,6 +433,25 @@ the private config repo with the read-only token of its own `builder` forge
|
|||
account. On a host without the store, that leaf is the one file to copy, as
|
||||
for the CI runner. What it builds and why are in [`builder.md`](builder.md).
|
||||
|
||||
### Binary cache
|
||||
|
||||
The swarm's attic server, in a `swarm-attic` container on the host that sets
|
||||
`deploy.attic.enable`. `allSwarmServices` defaults it on wherever the host has
|
||||
the cache's store identity, as for the builder: the host that runs the store has
|
||||
it. Set `deploy.attic.enable = lib.mkForce false` to use an external cache
|
||||
instead and name `swarm.attic.{domain,cache}` yourself.
|
||||
|
||||
The container shares the host's network namespace and atticd listens on loopback
|
||||
only. The gateway serves it at `swarm.attic.domain` (default
|
||||
`attic.<swarm domain>`) over TLS, with no login in front, because attic checks
|
||||
its own tokens. Storage is local disk in the container's state.
|
||||
|
||||
It needs no manual secret. Two host units, under the cache's own `attic` leaf,
|
||||
create its signing key, the cache and the push and pull tokens in the secret
|
||||
store, each only while absent. On a host without the store, that leaf is the one
|
||||
file to copy. The builder pushes green builds to it. How it works, and the
|
||||
external alternative, are in [`builder.md`](builder.md#binary-cache).
|
||||
|
||||
### CI metrics
|
||||
|
||||
The CI run poller, a `swarm-ci-metrics` oneshot on a 5-minute timer on the host
|
||||
|
|
|
|||
Loading…
Reference in a new issue