Single-node test book
Quick manual verification for SHC. Run on a single node with Docker.
Prerequisites
Section titled “Prerequisites”export SHC_VAULT_PASSWORD=shc1. Basics
Section titled “1. Basics”shc --versionshc vault unlockshc repo add local ./apps && shc repo sync localExpected: Version displayed, vault unlocked, repo synced without errors.
2. Stack Lifecycle
Section titled “2. Stack Lifecycle”shc install test-simple -s smokeshc ls # Shows "smoke" stackshc status smoke # Shows deployment + service healthshc stop -s smokeshc start -s smokeshc uninstall smoke -yExpected: Stack installs, stops, starts, uninstalls cleanly.
3. Stack Operations
Section titled “3. Stack Operations”shc install test-simple -s ops-testshc logs -s ops-test --tail 5shc exec -s ops-test --service app -- echo helloshc restart -s ops-testshc upgrade ops-testExpected: Logs shown, exec returns “hello”, restart and upgrade complete.
4. Backup & Restore
Section titled “4. Backup & Restore”mkdir -p /tmp/shc-backup-reposhc config set backup.repo "/tmp/shc-backup-repo" --scope baseshc config set backup.password "test-password" --scope base
shc backup create -s ops-testshc backup ls -s ops-testshc backup restore -s ops-test --before 1h --yesExpected: Backup created and listed; the --before restore picks
the pre-upgrade safety snapshot from step 3 and completes.
5. Clone & Move
Section titled “5. Clone & Move”shc clone ops-test ops-cloneshc ls # Shows both stacksshc uninstall ops-clone -y
shc move ops-test ops-renamedshc ls # Shows "ops-renamed"Expected: Clone creates copy, move renames stack.
6. Config & Vault
Section titled “6. Config & Vault”shc config set test.key "test-value" --scope baseshc config get test.keyshc config unset test.key --scope base
shc vault set MY_SECRET "secret-value"shc vault lsshc vault get MY_SECRETshc vault rm MY_SECRET -yExpected: Config and vault operations succeed, values match.
7. Scheduling
Section titled “7. Scheduling”shc schedule add -s ops-renamed backup "@daily"shc schedule ls -s ops-renamedshc schedule rm -s ops-renamed backup -yExpected: Schedule added, listed, removed.
8. Validation
Section titled “8. Validation”shc validate ./apps/test-simpleExpected: Validation passes with no errors.
9. Cleanup
Section titled “9. Cleanup”shc uninstall ops-renamed -yshc repo rm local -yrm -rf /tmp/shc-backup-reposhc ls # EmptyExpected: All test artifacts removed.
Quick Smoke Test
Section titled “Quick Smoke Test”Fastest possible verification (~30 seconds):
export SHC_VAULT_PASSWORD=shcshc vault unlockshc repo add local ./apps && shc repo sync localshc install test-simple -s smokeshc status smokeshc stop -s smoke && shc start -s smokeshc uninstall smoke -yshc repo rm local -yecho "Smoke test passed"shc@docs:~$