multisig-hsm/reference/gui_sim.sh
mineracks 7a17ffd12e Initial public release — multisig HSM reference + recipe book
Open-source 2-of-3 policy-enforced threshold HSM: auto-signs cold→hot treasury
refills under on-device Coldcard policy, no human in the loop. Includes the full
operator manual + quick-start, the reference coordinator/signing code, and a
signer-host bootstrap. No keys, seeds, or secrets — placeholders only.

Live signet demo: https://multisighsm.mineracks.com

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-26 13:56:51 +10:00

19 lines
813 B
Bash

#!/usr/bin/env bash
exec > /tmp/guisim.log 2>&1
set -x
export PATH="$HOME/gccshim:$PATH"
N="${1:-1}"; DISP=$((100+N)); VNC=$((5910+N)); WS=$((6910+N))
sudo DEBIAN_FRONTEND=noninteractive apt-get install -y -qq scrot >/dev/null 2>&1
pkill -f "Xvfb :$DISP" 2>/dev/null; pkill -f "x11vnc.*$VNC" 2>/dev/null; sleep 1
Xvfb :$DISP -screen 0 900x720x24 >/dev/null 2>&1 &
sleep 2
SEED=$(cat ~/cksim/seeds/$N.txt)
cd ~/coldcard-firmware/unix
DISPLAY=:$DISP ~/ccsim-venv/bin/python simulator.py --mk5 --seed "$SEED" >/tmp/guisim$N.log 2>&1 &
sleep 12
DISPLAY=:$DISP scrot /tmp/cc$N.png 2>&1
ls -l /tmp/cc$N.png
x11vnc -display :$DISP -rfbport $VNC -forever -shared -nopw -quiet -bg >/tmp/x11vnc$N.log 2>&1
setsid websockify $WS localhost:$VNC </dev/null >/tmp/ws$N.log 2>&1 &
echo "GUI_SIM_DONE disp=$DISP vnc=$VNC ws=$WS"