nixos: add comin, hosts pull their configuration from main
All checks were successful
nixos / nixos (push) Successful in 3m22s
All checks were successful
nixos / nixos (push) Successful in 3m22s
Each host runs comin, which polls main of this repository every minute, builds nixosConfigurations.<hostname> on the host and switches to it. A branch testing-<hostname> on top of main is applied with `test` to that host alone. Prometheus scrapes comin over the private network, and a failing fetch, evaluation, build or switch alerts after 15 minutes. CI still deploys this commit, which starts comin; the CI deploy job and its SSH key go in the next commit, once comin runs on both hosts. Assisted-by: Claude:opus-5-5
This commit is contained in:
parent
2635b887c7
commit
9290a4e181
1 changed files with 115 additions and 0 deletions
|
|
@ -181,6 +181,23 @@ groups:
|
|||
for: 6h
|
||||
labels: { severity: warning }
|
||||
annotations: { summary: "ejabberd's certificate expires {{ $values.A.Value | printf \"%.0f\" }} days before the one Traefik holds: the push or the reload failed" }
|
||||
- uid: deploy-failed
|
||||
title: "Deploy failing"
|
||||
condition: C
|
||||
data:
|
||||
- refId: A
|
||||
relativeTimeRange: { from: 900, to: 0 }
|
||||
datasourceUid: prometheus
|
||||
# comin: fetching main, evaluating, building or switching
|
||||
model: { refId: A, expr: "max by (host, __name__) ({__name__=~\"comin_last_(fetch|eval|build|deployment)_failed\"})", instant: true, intervalMs: 30000, maxDataPoints: 43200 }
|
||||
- refId: C
|
||||
datasourceUid: __expr__
|
||||
model: { refId: C, type: threshold, expression: A, conditions: [ { evaluator: { type: gt, params: [0] } } ] }
|
||||
noDataState: OK
|
||||
execErrState: Error
|
||||
for: 15m
|
||||
labels: { severity: warning }
|
||||
annotations: { summary: "{{ $labels.host }}: {{ $labels.__name__ }} (comin status on the host)" }
|
||||
- uid: replica-stale
|
||||
title: "Bucket replica stale"
|
||||
condition: C
|
||||
|
|
|
|||
Loading…
Reference in a new issue