Skip to content

Implement State Integrity Report CLI and validation #1

Description

@mdheller

Context

sourceos-syncd is now the canonical home for the SourceOS State Integrity Report and Index Lane model.

Specs and fixtures:

  • docs/specs/sourceos-state-integrity-report.md
  • docs/specs/sourceos-index-lanes.md
  • examples/health/healthy.snapshot.json
  • examples/health/degraded.snapshot.json
  • examples/health/repair-plan.json

Work

Implement the first non-destructive runtime surface:

  • sourceos-syncd health snapshot
  • sourceos-syncd health explain
  • sourceos-syncd health verify
  • sourceos-syncd repair plan

Do not implement destructive repair apply until the plan format, policy checks, checkpoint logic, and Lampstand evidence path are validated.

Acceptance criteria

  • CLI emits JSON matching the example shape.
  • health explain translates raw counters into diagnosis.
  • health verify checks journal, heartbeat, shadow/checkpoint, schema, tombstone, disk pressure, and policy invariants.
  • repair plan produces a non-destructive preview with preconditions, steps, blocked destructive steps, rollback, and postconditions.
  • Golden examples are used as fixtures in tests.
  • The implementation preserves health-of-health fields: partial collection, redaction, permission denied, timed out, unavailable.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions