34a44043f2
GP_GRIN1_RAIL now defaults OFF. Unset/off, GoblinPay behaves like the pre-rail server: no arti/Tor code path runs, no loopback Foreign API listener, no invoice slates issued, and the pay page shows ONLY 'Pay with Goblin' (no switcher, no grin1 UI, footer unchanged) — even for an invoice armed while the rail was on. Enabled, the two-rail switcher renders with the Goblin tab default-selected; the switcher chrome appears only when BOTH rails are available (a single rail renders its panel directly). - config: default flip + docs; env example + README gain the opt-in block. - checkout: build_info gates all grin1 UI on the flag; tests for both states (off => no rail-tab/rail-radio/panel-grin/grin1 strings; on => switcher with rail-goblin checked). - sqlx 0.8 -> 0.9 (workspace): its libsqlite3-sys range (<0.38) unifies with arti's rusqlite, resolving the one-links-per-native-lib conflict that otherwise forbids sqlx-sqlite + in-process arti in one binary. Feature map: runtime-tokio + sqlite (bundled, as before); dynamic COLUMNS queries wrapped in sqlx::AssertSqlSafe (compile-time composed strings).
44 lines
2.0 KiB
Bash
44 lines
2.0 KiB
Bash
# GoblinPay environment. Copy to /etc/goblinpay.env (bare metal) or deploy/.env
|
|
# (docker compose), then edit. NON-SECRET config only: the Grin seed and the
|
|
# wallet password live as mode-0400 files (systemd LoadCredential / the compose
|
|
# ./secrets mount), never in this file.
|
|
|
|
# --- domain / URLs ---
|
|
# docker-compose serves GoblinPay on GP_DOMAIN and the bundled relay on
|
|
# relay.<GP_DOMAIN>; point BOTH DNS records at this host before `compose up`.
|
|
GP_DOMAIN=pay.example
|
|
GP_PUBLIC_URL=https://pay.example
|
|
|
|
# --- relay (bundled is the default: GoblinPay runs its own relay) ---
|
|
GP_RELAY_MODE=bundled
|
|
# The bundled relay's PUBLIC url: it is BOTH dialed by the server AND advertised
|
|
# to payers in the checkout nprofile, so it must be reachable from the internet.
|
|
GP_BUNDLED_RELAY_URL=wss://relay.pay.example
|
|
# For GP_RELAY_MODE=external instead, drop the bundled relay and set:
|
|
#GP_RELAY_MODE=external
|
|
#GP_RELAYS=wss://relay.damus.io,wss://nos.lol
|
|
|
|
# --- Grin node (read-only: confirmations + balance) ---
|
|
GP_NODE_URL=https://main.gri.mw
|
|
|
|
# --- API / admin tokens (bearer capabilities; use strong random values) ---
|
|
GP_API_TOKEN=change-me-api-token
|
|
GP_ADMIN_TOKEN=change-me-admin-token
|
|
|
|
# --- webhook to your store (optional; the URL requires the secret) ---
|
|
#GP_WEBHOOK_URL=https://your-store/hook
|
|
#GP_WEBHOOK_SECRET=change-me-webhook-secret
|
|
|
|
# --- default payment-matching mode: memo | derived | amount ---
|
|
GP_MATCH_MODE=derived
|
|
|
|
# --- grin1 / Tor rail (operator opt-in; PACKAGED DEFAULT OFF) ---
|
|
# When off (or unset) GoblinPay is Goblin/Nostr-only: no Tor onion service, no
|
|
# local Foreign API listener, and the pay page shows only "Pay with Goblin".
|
|
# Set to `on` to also accept payments from ANY Grin wallet over Tor: the till
|
|
# publishes an onion service whose identity IS its grin1 slatepack address key
|
|
# (grin1 address == onion address), serving the Grin Foreign API v2.
|
|
#GP_GRIN1_RAIL=on
|
|
# Loopback port the Foreign API binds (the onion service proxies to it).
|
|
#GP_GRIN1_FOREIGN_PORT=3416
|