Commit graph

7 commits

Author SHA1 Message Date
Marco Allegretti
d37f6e6015 perf(store): stream metadata checksum
Avoid allocating pretty-JSON just to hash it by streaming\nserialization into a blake3 hasher. Keeps checksum bytes\ncompatible and adds a regression test.
2026-02-25 20:15:47 +01:00
Marco Allegretti
cad64482c0 chore: trim runtime/store comments 2026-02-25 13:24:02 +01:00
Marco Allegretti
c1e2650617 fix(store): avoid panic in metadata checksum 2026-02-25 12:48:11 +01:00
Marco Allegretti
961209ef0a fix: harden enter/stop and WAL recovery
- Guard WAL recovery and stale .running cleanup behind a try-acquired store lock\n- Persist rollback ResetState via MetadataStore to recompute checksums\n- Track a killable host PID for namespace enter/stop and treat SIGTERM/SIGKILL as clean exit\n- Derive OCI status PID via runtime state output\n- Make sandbox chroot script quoting robust for exec/enter
2026-02-25 11:48:58 +01:00
Marco Allegretti
62b9b569be fix supply chain: bump cargo-cyclonedx 0.5.7, fix SBOM generation, fix rmeta test
- Bump cargo-cyclonedx from 0.5.5 to 0.5.7 (supports lockfile v4)
- Generate SBOM for karapace-cli crate only (single predictable file)
- Fix --output-prefix → --override-filename (CLI change in 0.5.x)
- Fix rmeta tampering test: accept build failure as valid defense
  (cargo rejects corrupted .rmeta with compilation errors)
2026-02-22 20:31:08 +01:00
Marco Allegretti
37211dfd22 fix CI: fmt, skip migrate readonly test as root, fix container shell
- Run cargo fmt on skip_if_root() blocks
- Add skip_if_root() to migrate_atomic_version_unchanged_on_write_failure
- Add libc dev-dependency to karapace-store for root check
- Remove explicit shell: sh from container rustup steps (OCI exec
  can't find sh in PATH; default run shell works)
2026-02-22 20:11:09 +01:00
Marco Allegretti
4de311ebc7 feat: karapace-store — content-addressable object store, layers, metadata, WAL
- ObjectStore: blake3-addressed objects, atomic writes (NamedTempFile + persist)
- Integrity verification on every read (hash comparison without String allocation)
- LayerStore: layer manifests with Base/Dependency/Policy/Snapshot kinds
- MetadataStore: environment state machine, naming, ref-counting, blake3 checksum
- GarbageCollector: signal-cancellable orphan cleanup, protects live references
- WriteAheadLog: crash recovery with typed rollback steps (RemoveDir/RemoveFile/ResetState)
- StoreLayout: #[inline] path accessors, store format v2 versioning
- Store migration: v1→v2 with atomic version file rewrite
- Deterministic tar packing/unpacking (sorted entries, zero timestamps, uid/gid 0)
- fsync_dir() for POSIX-portable rename durability
2026-02-22 18:36:31 +01:00