generated from coulomb/repo-seed
Implement SAND-WP-0002 meta-framework foundation (T01–T09)
Add meta-framework spec, pydantic schemas, profile/extension YAML, extension registry, ext.compose-ssh backend, SandboxManager with State Hub events, CLI commands, integration docs, capability registry entry, and compose-e2e runbook. Nine unit tests pass. T10 remote smoke test remains for operator.
This commit is contained in:
90
docs/runbooks/profile-compose-e2e.md
Normal file
90
docs/runbooks/profile-compose-e2e.md
Normal file
@@ -0,0 +1,90 @@
|
||||
# Runbook: profile.compose-e2e
|
||||
|
||||
Provision a compose-based e2e sandbox via `ext.compose-ssh` (e2e-framework lineage).
|
||||
|
||||
## Prerequisites
|
||||
|
||||
**Workstation**
|
||||
|
||||
- `uv`, `ssh`, `rsync`
|
||||
- sand-boxer installed: `make setup`
|
||||
|
||||
**Remote host** (CoulombCore or sandboxer01)
|
||||
|
||||
- SSH access (`SANDBOXER_HOST` or `--host`)
|
||||
- Docker + compose plugin
|
||||
- Sufficient disk for images
|
||||
|
||||
```bash
|
||||
export SANDBOXER_HOST=<ip-or-hostname> # e.g. coulombcore IP
|
||||
export SANDBOXER_SSH_USER=root # optional
|
||||
export SANDBOXER_SSH_KEY=~/.ssh/id_rsa # optional
|
||||
```
|
||||
|
||||
## Create
|
||||
|
||||
Target repo must contain `e2e/e2e.yml` (for compose file path) or a
|
||||
`docker-compose*.yml` at repo root.
|
||||
|
||||
```bash
|
||||
sandboxer create \
|
||||
--profile profile.compose-e2e \
|
||||
--input repo=/path/to/repo \
|
||||
--actor adm \
|
||||
--project sand-boxer
|
||||
```
|
||||
|
||||
Confirm `state: ready` and note `reachability.ssh`, `reachability.remote_dir`,
|
||||
and `reachability.compose_project`.
|
||||
|
||||
## Manual readiness check
|
||||
|
||||
sand-boxer confirms compose services are running (not HTTP health — that is
|
||||
wise-validator's job):
|
||||
|
||||
```bash
|
||||
ssh $SANDBOXER_SSH_USER@$SANDBOXER_HOST \
|
||||
'docker compose -p <compose_project> -f <remote_dir>/<compose_file> ps'
|
||||
```
|
||||
|
||||
## Destroy
|
||||
|
||||
```bash
|
||||
sandboxer destroy <sandbox_id>
|
||||
```
|
||||
|
||||
Verify cleanup:
|
||||
|
||||
```bash
|
||||
ssh $SANDBOXER_SSH_USER@$SANDBOXER_HOST 'docker compose ls'
|
||||
ssh $SANDBOXER_SSH_USER@$SANDBOXER_HOST 'ls /tmp/sandboxer/'
|
||||
```
|
||||
|
||||
## Compatibility with legacy `make e2e`
|
||||
|
||||
Interim callers in `the-custodian` should migrate to sand-boxer for
|
||||
provision/teardown only. Test execution remains in wise-validator (SAND-WP-0003).
|
||||
|
||||
| Legacy | sand-boxer |
|
||||
|--------|------------|
|
||||
| `make e2e REPO=foo` (full pipeline) | `sandboxer create` + wise-validator run |
|
||||
| rsync + compose up | `ext.compose-ssh` provision |
|
||||
| compose down + dir removal | `sandboxer destroy` |
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
**Provision fails — no compose file**
|
||||
|
||||
Ensure repo has `e2e/e2e.yml` with `compose_file` or a root `docker-compose*.yml`.
|
||||
|
||||
**Leftover compose projects**
|
||||
|
||||
```bash
|
||||
ssh $SANDBOXER_HOST 'docker compose -p sbx-e2e-<id> down -v; rm -rf /tmp/sandboxer/<id>'
|
||||
```
|
||||
|
||||
**Skip State Hub events (local debug)**
|
||||
|
||||
```bash
|
||||
export SANDBOXER_NO_STATE_HUB=1
|
||||
```
|
||||
Reference in New Issue
Block a user