chore: stub regtest.sh + fakewallet.sh dispatchers
Both scripts are placeholders that document the intended dispatcher shape (up/down/logs/shell). fakewallet.sh is a deliberate no-op for symmetry — same muscle memory whether the backend is a docker stack or a constant. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
a21428e482
commit
c4bf077636
2 changed files with 74 additions and 0 deletions
36
modules/dev-env/scripts/regtest.sh
Executable file
36
modules/dev-env/scripts/regtest.sh
Executable file
|
|
@ -0,0 +1,36 @@
|
|||
#!/usr/bin/env bash
|
||||
# regtest.sh — wrapper around a Bitcoin/Lightning regtest docker stack.
|
||||
#
|
||||
# Mirrors the workflow of `lnbits/legend-regtest-enviroment` (LND + CLN
|
||||
# + Eclair + bitcoind + electrs). Cloned to
|
||||
# `${dev-env.root}/local/docker/regtest/` by the bootstrap script
|
||||
# (later pass); this wrapper just dispatches `up` / `down` / `logs` /
|
||||
# `shell` to the underlying docker-compose stack.
|
||||
#
|
||||
# Symmetric with fakewallet.sh so the dev experience reads the same
|
||||
# whether you're on the default FakeWallet path or the regtest stack:
|
||||
#
|
||||
# regtest up # boot the regtest stack
|
||||
# regtest down # tear it down
|
||||
# regtest logs # tail compose logs
|
||||
# regtest shell # drop into a node container
|
||||
#
|
||||
# Once `regtest up` is healthy, point LNbits at the appropriate
|
||||
# backend (LndRestWallet / CoreLightningWallet) by flipping
|
||||
# `lnbits-sensei.lnbits.backend` and rebuilding.
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
# TODO(skeleton): replace with real dispatcher in the substantive pass.
|
||||
# Intended shape:
|
||||
# case "${1:-}" in
|
||||
# up) docker compose -f "${REGTEST_DIR}/docker-compose.yml" up -d ;;
|
||||
# down) docker compose -f "${REGTEST_DIR}/docker-compose.yml" down ;;
|
||||
# logs) docker compose -f "${REGTEST_DIR}/docker-compose.yml" logs -f ;;
|
||||
# shell) docker compose -f "${REGTEST_DIR}/docker-compose.yml" exec "${2}" sh ;;
|
||||
# *) usage ;;
|
||||
# esac
|
||||
|
||||
echo "regtest: TODO — substantive implementation lands in a later pass."
|
||||
echo "See modules/dev-env/scripts/regtest.sh for the intended dispatcher shape."
|
||||
exit 0
|
||||
Reference in a new issue