- load-project-env: _lpr_dotenv_source / _lpr_source_relaxed so smom-dbis-138/.env
lines like ${ARBITRUM_MAINNET_RPC} do not abort scripts using set -u
- check-public-report-api: detect /token-aggregation vs apex /api/v1 for networks
- run-completable-tasks: enforce public report API (remove SKIP_EXIT bypass)
- Document verifier behavior in TOKEN_AGGREGATION_REPORT_API_RUNBOOK and verify README
Made-with: Cursor
Verification Scripts
Scripts for ingress, NPMplus, DNS, and source-of-truth verification.
Dependencies
Required tools (install before running):
| Tool | Purpose | Install |
|---|---|---|
bash |
Shell (4.0+) | Default on most systems |
curl |
API calls, HTTP | apt install curl |
jq |
JSON parsing | apt install jq |
dig |
DNS resolution | apt install dnsutils |
openssl |
SSL certificate inspection | apt install openssl |
ssh |
Remote execution | apt install openssh-client |
ss |
Port checking | apt install iproute2 |
systemctl |
Service status | System (systemd) |
sqlite3 |
Database backup | apt install sqlite3 |
Optional (recommended for automation): sshpass, rsync, screen, tmux, htop, shellcheck, parallel. See docs/11-references/APT_PACKAGES_CHECKLIST.md § Automation / jump host.
One-line install (Debian/Ubuntu): sudo apt install -y sshpass rsync dnsutils iproute2 screen tmux htop shellcheck parallel
| Tool | Purpose |
|---|---|
wscat or websocat |
WebSocket testing (manual verification) |
Scripts
backup-npmplus.sh- Full NPMplus backup (database, API exports, certificates)check-contracts-on-chain-138.sh- Check that Chain 138 deployed contracts have bytecode on-chain (cast codefor 31 addresses; requirescastand RPC access). Use[RPC_URL]or envRPC_URL_138;--dry-runlists addresses only (no RPC calls);SKIP_EXIT=1to exit 0 when RPC unreachable.check-public-report-api.sh- Verify token-aggregation report + networks JSON (not Blockscout). Probes/api/v1/networksfirst, then/token-aggregation/api/v1/networks, and uses the working prefix for all checks. UseSKIP_EXIT=1for diagnostic-only mode. SetSKIP_BRIDGE_ROUTES=0/SKIP_BRIDGE_PREFLIGHT=0for bridge assertions.check-token-aggregation-chain138-api.sh- Hits tokens, pools, quote,bridge/routes,bridge/status,bridge/preflight, and networks on both/api/v1/*and/token-aggregation/api/v1/*.BASE_URL=https://explorer.d-bis.org(default) orhttp://192.168.11.140.check-gru-transport-preflight.sh- Operator-focused GRU runtime preflight. Calls/api/v1/bridge/preflight, prints blocked pairs witheligibilityBlockers/runtimeMissingRequirements, and fails unless all active pairs are runtime-ready orALLOW_BLOCKED=1is set.check-cstar-v2-transport-stack.sh- Predeploy Forge verifier for thec* V2bridge stack. Runs the base V2 token suite, legacy reserve-verifier compatibility suite, V2 reserve/verifier full L1/L2 round-trip suite, and the coreCWMultiTokenBridgeround-trip suite.run-repo-green-test-path.sh- Local deterministic green-path aggregate behind rootpnpm test. Runs config validation, then the focusedsmom-dbis-138contract and service CI targets.xdc-zero-chain138-preflight.sh-eth_chainIdHTTP checks forXDC_PARENTNET_URL/PARENTNET_URLandRPC_URL_138; optionalETHEREUM_MAINNET_RPC,BSC_RPC_URL. See CHAIN138_XDC_ZERO_BRIDGE_RUNBOOK.../xdc-zero/merge-endpointconfig-chain138.sh- Mergechain138into XDC-Zeroendpointconfig.json(optionalxdcparentnet.registersappend). SetXDC_ZERO_ENDPOINT_DIR; use--dry-run. See config/xdc-zero/README.md.check-completion-status.sh- One-command summary of repo-completable checks, public report API health, and pointers to operator/external remaining work.reconcile-env-canonical.sh- Emit recommended .env lines for Chain 138 (canonical source of truth); use to reconcilesmom-dbis-138/.envwith CONTRACT_ADDRESSES_REFERENCE. Usage:./scripts/verify/reconcile-env-canonical.sh [--print]check-deployer-balance-blockscout-vs-rpc.sh- Compare deployer native balance from Blockscout API vs RPC (to verify index matches current chain); see EXPLORER_AND_BLOCKSCAN_REFERENCEsync-blockscout-address-labels-from-registry.sh- Plan or sync Blockscout address labels fromaddress-registry-entryJSON (config/dbis-institutional/schemas/address-registry-entry.schema.json:blockscout.label,status: active). Supports--mode=http,--mode=db, and--mode=auto; on the self-hosted Chain 138 explorer,dbis the right live mode because/api/v1/*is token-aggregation, not a native Blockscout label-write API. DB mode writes primary labels into Blockscoutpublic.address_namesthrough CT5000. Seeconfig/dbis-institutional/README.mdand OMNL_DBIS_CORE_CHAIN138_SMART_VAULT_RTGS_RUNBOOK.md.check-dependencies.sh- Verify required tools (bash, curl, jq, openssl, ssh)export-cloudflare-dns-records.sh- Export Cloudflare DNS recordsexport-npmplus-config.sh- Export NPMplus proxy hosts and certificates via APIgenerate-source-of-truth.sh- Combine verification outputs into canonical JSONrun-full-verification.sh- Run full verification suiteverify-backend-vms.sh- Verify backend VMs (status, IPs, nginx configs)verify-end-to-end-routing.sh- E2E routing verificationverify-udm-pro-port-forwarding.sh- UDM Pro port forwarding checksverify-websocket.sh- WebSocket connectivity test (requires websocat or wscat)
Task runners (no LAN vs from LAN)
- From anywhere (no LAN/creds):
../run-completable-tasks-from-anywhere.sh— runs config validation, on-chain contract check, run-all-validation --skip-genesis, public report API diagnostics, and reconcile-env-canonical. - Completion snapshot:
check-completion-status.sh— summarizes what is complete locally and what still depends on operator or external execution. - Full LAN execution order:
../run-full-operator-completion-from-lan.sh— starts with the token-aggregation/api/v1repair, then Wave 0, verification, E2E, and optional operator-only deployment steps. Use--dry-runfirst. - From LAN (NPM_PASSWORD, optional PRIVATE_KEY):
../run-operator-tasks-from-lan.sh— runs W0-1 (NPMplus RPC fix), W0-3 (NPMplus backup), O-1 (Blockscout verification); use--dry-runto print commands only. See ALL_TASKS_DETAILED_STEPS.
Environment
Set variables in .env or export before running. See project root .env.example and docs/04-configuration/VERIFICATION_GAPS_AND_TODOS.md.