Disk writes:
- SQLite pragmas in DSN: wal_autocheckpoint=10000, journal_size_limit=64MB, cache_size=64MB
- migration 0013: drop redundant idx_checks_registry_cycle
- results batched: UpsertChecksIfOpen in one transaction; agent flushes every 5s and before complete
- heartbeat kept in memory, persisted on state change or every 60s; startup grace for stale sweeps
Diagnostic mode:
- POST /api/v1/admin/diagnostics/attach|detach, GET /api/v1/admin/diagnostics
- migration 0014: diagnostic_holds; validator state "diagnostic"
- held addresses are not queued, held validators skip sweeps, port release and delete
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The role resolves image_tag to a digest once per run and pulls that image
on every validator before replacing the container; the git and build
steps are gone. scripts/publish-agent-image.sh builds and pushes the
agent image (<rev12> and latest tags).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The role warns about new variables missing from the env file and, after
the container starts, checks that traceroute is installed and the agent
config has the retry and traceroute settings.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The real container on the validators is named validator-agent (the image
is cloud-ip-validator-validator-agent); the playbook used the image name
as the container name, so it would have started a second agent next to
the old one with the same validator_id. The clone on the validators is
owned by root, so git must run as root (git_user), otherwise fetch fails
with "cannot open .git/FETCH_HEAD: Permission denied".
Preflight now stops when the host has another container of this agent
(by name or image) besides container_name.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Run from the jump host: on each validator it updates the git clone in
/opt/cloud-ip-validator, builds the image there, stops and removes the
current container and starts a new one from the new image. Run
parameters live in an env file (deploy/ansible/env/validator-agent.env,
git-ignored, template committed).
The image is built before the running container is touched, so a failed
build leaves the old container running. Hosts are updated in waves
(1, 4, rest) and any failure stops the run. validator_id comes from the
inventory and is checked against the running container before it is
replaced. Only ansible.builtin modules are used, so the validators need
no extra packages.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>