Retain redacted runtime drift evidence before Device Core rollback
This commit is contained in:
@@ -0,0 +1,105 @@
|
||||
# Device Core automatic deployment acceptance
|
||||
|
||||
Date: 2026-09-29. First automatic release accepted; the second was rejected by runtime
|
||||
acceptance and successfully rolled back. Ordered-release acceptance remains open. This report concerns Device Core only. B2 multi-client contours are
|
||||
a separate implementation in `NODEDC_MISSION_CORE_ARNAVI-VPS`.
|
||||
|
||||
## Installed authority
|
||||
|
||||
Platform source: `f7416bc59a19a9ac53c4f4591eaf50a7f4a41641`.
|
||||
Root runner SHA-256:
|
||||
`c1301d1072f3d5d39ba422a09847a05a5aad8a753c816d7fb6916d1f1cadd9c6`.
|
||||
The operator's promotion returned `verify-install-ok`, Python3.8.15.
|
||||
|
||||
Controller artifact:
|
||||
`nodedc-device-core-autodeploy-v1-20260929-001.tgz`, SHA-256
|
||||
`fe9298baa5f41a35c2705ee9946b730ff2de7d5b5c9b2b8eb1b4cca0bc8ed12b`.
|
||||
Canonical ledger386 records success at18:35:52Z, with backup
|
||||
`device-core-autodeploy-device-core-autodeploy-v1-20260929-001-20260929-213533`.
|
||||
Native timer, private token import, no published ports and preservation of
|
||||
existing applications were checked by canonical apply.
|
||||
|
||||
The temporary Mac token file and NAS enrollment staging were removed after
|
||||
private import. The NAS retains its root-private working credential and queue.
|
||||
The observer on the Mac only reads Gitea/SMB and verifies hashes; it has no
|
||||
stage, plan or apply role in these automatic releases.
|
||||
|
||||
## Two consecutive main pushes
|
||||
|
||||
Both commits were pushed before the first release completed, without a manual
|
||||
NAS plan/apply. Build runner1 has capacity1. The controller orders releases by
|
||||
their durable run identity and invokes the canonical installer itself.
|
||||
|
||||
| Run | Device Core source | Artifact SHA-256 | Canonical result |
|
||||
| --- | --- | --- | --- |
|
||||
| 8 | `154f243cfde4c9407a28c4d0cb63d29b4cea7c4c` | `2d830958572509df220125a90251d1106abee50e5d891852140e83496ba325f6` | ledger387, success18:56:55Z |
|
||||
| 9 | `e912e6ffaf7e142afa02254c6c48ac645eb2db63` | `5e678e69b316ceb547112c45ac51cc2294b2f301f2bdc380bcf4347e504739fb` | failed ledger79, clean rollback19:04:04Z |
|
||||
|
||||
Each artifact basename is
|
||||
`nodedc-device-core-release-v1-r<RUN>-<FULL-SOURCE-SHA>.tgz`.
|
||||
Run8 backup:
|
||||
`device-core-release-device-core-release-v1-r8-154f243cfde4c9407a28c4d0cb63d29b4cea7c4c-20260929-215159`.
|
||||
Its archive digest matches the independently retrieved Gitea receipt; the inbox
|
||||
entry is absent, there is exactly one applied receipt and no failed receipt.
|
||||
The lifecycle inspector classifies it as `terminal_success`; never replay it.
|
||||
|
||||
## Actual interruption and product checks
|
||||
|
||||
After staging run8, a subsequent Gitea request failed with `api_unavailable`
|
||||
at18:51:05Z. The controller retained the candidate and automatically resumed;
|
||||
its backup was created at18:51:59Z, followed by successful application at18:56:55Z.
|
||||
No operator command, new commit, timeout expiry or re-enrollment was required.
|
||||
This verifies one observed network-interruption recovery, not every outage case.
|
||||
|
||||
Only Core and Manager are rebuilt/recreated by the normal release domain.
|
||||
Canonical acceptance checks selected generations/images, exact source and
|
||||
runtime configuration, health, database/Gateway/backhaul preservation and other
|
||||
Compose services. A green CI run alone is never treated as deployment.
|
||||
|
||||
After run8, the public Manager `/healthz` returned200 with `ok`, `authRequired`
|
||||
and `deviceCoreConfigured` true. The authenticated browser rendered Device Core
|
||||
as DC SUDO, opened Devices and retained DCTOUCH and
|
||||
Robot2B — Moscow Trike Delivery in the owner/project selectors.
|
||||
|
||||
## Reproducible normal use and limits
|
||||
|
||||
Push to Device Core `main` from any computer. Read qualification in Gitea Actions;
|
||||
read installation from the canonical applied journal and its archive/backup.
|
||||
The controller's sanitized `runtime-status.json` is the last completed cycle;
|
||||
it can still show that cycle while a new build/apply runs. `waiting` after a
|
||||
release does not mean the installed release disappeared.
|
||||
|
||||
Main application updates need no SMB copy, SSH session or per-commit sudo.
|
||||
Root-runner changes, schema/build foundation migrations, topology changes and
|
||||
onboarding another repository remain separately registered infrastructure work.
|
||||
The ordinary release domain intentionally cannot introduce those transitions.
|
||||
|
||||
Source tests cover failed/pending CI, duplicate/overlapping runs, changed
|
||||
pagination, mismatched identities, crash reservation reconciliation and clean or
|
||||
uncertain rollback. Run9 encountered a real Manager configuration mismatch and passed automatic
|
||||
rollback. Production was not deliberately crashed for this acceptance. Fleet capacity, B2 auth and contour isolation
|
||||
are not established by these deployment checks.
|
||||
|
||||
## Run9 incident
|
||||
|
||||
The canonical failure is `Device Core release runtime configuration drift:
|
||||
device-manager`, failed ledger79, rollback `ok:device-core-release` at19:04:04Z.
|
||||
The failed archive is the run9 basename with suffix `.20260929-215803`.
|
||||
Its digest and backup are verified; it must never be replayed. Run8 remains the
|
||||
accepted source. The old before snapshot retains only an aggregate configuration
|
||||
hash, so the exact differing field was not retained before rollback removed the
|
||||
failed container. Two-network NetworkMode selection is a hypothesis, not a
|
||||
proven cause. Add per-field hash evidence without changing acceptance semantics
|
||||
before attempting a forward fix.
|
||||
|
||||
The prepared instrumentation keeps fingerprint v2 unchanged and records only
|
||||
per-field hashes plus the names of changed fields in the canonical failure
|
||||
receipt. Eight focused evidence cases cover redaction, stable container identity,
|
||||
mount-order equivalence versus option changes, network mismatch rejection and
|
||||
legacy snapshots. An additional real apply/rollback dispatcher test confirms
|
||||
that the diagnostic survives rollback in the failed journal.
|
||||
Validation:75 Device Core release/bootstrap/recovery tests;75 registry tests
|
||||
(1 historical skip);170 Device Core artifact tests (17 historical skips);
|
||||
Python3.8 syntax and diff checks. Runner candidate SHA-256:
|
||||
`3eefc75591bb08339d79c6a484912d7d6a8881fe8729e966b6f0bf32da21da80`.
|
||||
It is prepared, not installed. No new release has been submitted after run9.
|
||||
@@ -2,8 +2,11 @@
|
||||
|
||||
Status: 2026-09-29. The build runner is installed and push-to-main qualification
|
||||
works. Release r7 (`edf69068ec64e3d105d5324d39b8eaeface21215`) is accepted
|
||||
in canonical ledger 385. Production polling is **not activated**. DCPLATFORM-21 owns the deployment
|
||||
contract; DCPLATFORM-37 tracks activation.
|
||||
in canonical ledger 385. The outbound production controller was activated by
|
||||
`device-core-autodeploy-v1-20260929-001` in ledger 386 at18:35:52Z on2026-09-29.
|
||||
Run8 deployed automatically; run9 failed Manager runtime configuration acceptance
|
||||
and rolled back successfully. Full ordered-release acceptance remains open.
|
||||
DCPLATFORM-21 owns the deployment contract; DCPLATFORM-37 tracks acceptance.
|
||||
|
||||
## Release domain
|
||||
|
||||
@@ -102,22 +105,46 @@ The frozen generic `run_compose` function is byte-identical to the previous Engi
|
||||
canon. Device Core uses its own exact Core+Manager Compose entry with unchanged
|
||||
`--pull never --no-build --no-deps`, including rollback.
|
||||
|
||||
## Remaining activation work
|
||||
## Activation and acceptance
|
||||
|
||||
- Promote the reviewed root runner through the separate SHA-pinned admin gate.
|
||||
- Build/stage the bootstrap via `build_autodeploy.py`, then fresh plan and apply.
|
||||
- Accept a new main commit through CI → automatic canonical deployment, including
|
||||
ordered commits, failed checks and recovery. Source tests are not NAS acceptance.
|
||||
- Remove the temporary Mac token copy after private NAS import is verified.
|
||||
- Runner012 was promoted and verified as
|
||||
`c1301d1072f3d5d39ba422a09847a05a5aad8a753c816d7fb6916d1f1cadd9c6`.
|
||||
- The data-only bootstrap built by `build_autodeploy.py` passed fresh plan/apply;
|
||||
artifact SHA is `fe9298baa5f41a35c2705ee9946b730ff2de7d5b5c9b2b8eb1b4cca0bc8ed12b`.
|
||||
- NAS imported its root-private credential and removed enrollment staging. The
|
||||
temporary Mac credential was removed after acceptance. Neither a Mac nor SMB
|
||||
needs to remain connected for recurring delivery.
|
||||
- Ordered automatic releases are being verified against their CI receipts,
|
||||
archive digests, unique canonical journal rows and backups. Failed-check and
|
||||
crash/reconciliation tests are source qualification, not a claim that the NAS
|
||||
was deliberately crashed during production acceptance.
|
||||
|
||||
No helper from this directory is executed on NAS or installed by an application
|
||||
release. User-facing NAS deployment commands remain canonical plan/apply.
|
||||
|
||||
## Validation
|
||||
|
||||
Run9 was rejected for a Manager runtime configuration difference and rolled back
|
||||
successfully to run8. Its failed archive must not be replayed. The initial
|
||||
snapshots retained only an aggregate configuration hash, so the specific field
|
||||
was not available after rollback removed the failed container.
|
||||
|
||||
The next runner candidate adds diagnostic field hashes to new before snapshots.
|
||||
It binds each observation to the checked container/image/configuration identity.
|
||||
On a mismatch, the canonical failed receipt retains changed field names and
|
||||
their hashes before the failed generation is removed. Raw environment values,
|
||||
inspect payloads and external exception text are not included. The v2 comparison,
|
||||
network/mount semantics, selected services and rollback checks are unchanged.
|
||||
Old snapshots still use their original aggregate hash. This instrumentation is
|
||||
not a fix for an as-yet-unidentified configuration difference and is not installed
|
||||
until the separate root promotion succeeds.
|
||||
|
||||
See [live acceptance and the run9 incident](ACCEPTANCE_20260929.md).
|
||||
|
||||
```sh
|
||||
python3 -m unittest discover -s infra/device-core-deploy -p 'test_*.py'
|
||||
python3 -m unittest discover -s infra/deploy-runner -p test_device_core_release.py
|
||||
python3 -m unittest discover -s infra/deploy-runner -p test_device_core_runtime_evidence.py
|
||||
python3 -m unittest discover -s infra/gitea-ci -p 'test_*.py'
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user