feat(mvp): working secrets-engine CLI for the whynot-design npm publish lane
Implements SECRETS-WP-0002 end to end as a uv-managed Python package: - catalog: non-secret lane registry + strict validator (build/test/prod) - stage roles + OpenBao ACL policies; guards refuse wildcards, sys/, identity/, admin names, and cross-stage paths before any backend call - plan/apply: dry-run-first, idempotent policy + approle apply, decision-gated - decisions: State Hub lookup with local-fixture fallback; non-secret evidence to JSONL + hub progress, scrubbed of any value - provision/verify: mode-0600 file import + generated test values; positive/ negative checks that never print the value - exec delivery: `exec --catalog ... -- npm publish` injects the token via a temp .npmrc for the child only, cleaned up on exit/failure/interrupt - ops-warden routing contract + hardening backlog docs - 34 tests incl. live OpenBao integration; scripts/demo-e2e.sh runs the full chain against a throwaway bao dev server Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
parent
58c24cff53
commit
a852d3f1ff
47 changed files with 3743 additions and 122 deletions
|
|
@ -1,27 +1,34 @@
|
|||
## Stack
|
||||
|
||||
- **Language:** Markdown-first registry and planning repo (no application runtime yet)
|
||||
- **Key deps:** State Hub ADR-001 workplans, `registry/indexes/capabilities.yaml`
|
||||
- **Language:** Python 3.11+ CLI (`src/secrets_engine/`), `uv`-managed, hatchling build
|
||||
- **Backend:** OpenBao, reached only via the `bao` CLI adapter (`openbao.py`)
|
||||
- **Key deps:** PyYAML (runtime), pytest (dev); State Hub for decisions/evidence
|
||||
- **Entry point:** `secrets-engine` (console script → `secrets_engine.cli:main`)
|
||||
|
||||
## Dev Commands
|
||||
|
||||
```bash
|
||||
# Install (editable, with dev extras)
|
||||
uv venv && uv pip install -e ".[dev]"
|
||||
source .venv/bin/activate
|
||||
|
||||
# Run the CLI
|
||||
secrets-engine --version
|
||||
secrets-engine catalog list
|
||||
|
||||
# Test (unit + live OpenBao integration; integration auto-skips without `bao`)
|
||||
SECRETS_ENGINE_HUB_URL="" python -m pytest -q
|
||||
|
||||
# Full pilot chain live against a throwaway OpenBao dev server
|
||||
SECRETS_ENGINE_HUB_URL="" bash scripts/demo-e2e.sh
|
||||
|
||||
# Orient (offline-safe)
|
||||
cat .custodian-brief.md
|
||||
cat README.md
|
||||
cat SCOPE.md
|
||||
ls workplans/
|
||||
|
||||
# Consumer bootstrap docs
|
||||
cat docs/statehub-register.md
|
||||
cat docs/template-validation-checklist.md
|
||||
# After workplan edits — from ~/state-hub
|
||||
make fix-consistency REPO=secrets-engine
|
||||
|
||||
# After workplan or registry edits — from ~/state-hub
|
||||
make fix-consistency REPO=repo-seed
|
||||
|
||||
# Validate registry entries (from reuse-surface checkout)
|
||||
reuse-surface validate --root .
|
||||
|
||||
# Sanity-check markdown / registry edits
|
||||
# Sanity-check edits
|
||||
git diff --check
|
||||
```
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue