The upstream SpacesOps app refactored its SUBSD_* environment variables to SUBS_* (verified against server.js in spacesops/spacesops:v1.0.0). Update the package to match so the configured values reach the app: - main.ts: inject SUBS_URI_VALUE / SUBS_RPC_USER / SUBS_RPC_PASSWORD. - configurePlatform action + storeJson: rename store keys subsd*→subs* and the field labels/descriptions (SUBS URL / SUBS RPC User / SUBS RPC Password). - README, instructions, release notes: SUBSD→SUBS. Note: the image's /app/setup-spacesops-env.sh still exports SUBSD_* defaults (partial upstream refactor) — see report; vars the package does not set (e.g. SUBS_RPC_URL) currently have no in-image default. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
25 lines
1.0 KiB
TypeScript
25 lines
1.0 KiB
TypeScript
import { FileHelper, z } from '@start9labs/start-sdk'
|
|
import { sdk } from '../sdk'
|
|
|
|
const shape = z.object({
|
|
// Nostr operator keypair — generated once in init, or replaced via the
|
|
// "Import Operator Key" action. SpacesOps signs operator events with it.
|
|
operatorSecretHex: z.string().nullable().catch(null),
|
|
operatorPublicHex: z.string().nullable().catch(null),
|
|
// Strong replacement for the app's weak hardcoded session secret.
|
|
sessionSecret: z.string().nullable().catch(null),
|
|
// Optional config set via the "Configure Platform" action.
|
|
platformMode: z.enum(['prod', 'test']).nullable().catch(null),
|
|
operatorRelay: z.string().nullable().catch(null),
|
|
coingeckoApiKey: z.string().nullable().catch(null),
|
|
coingeckoTokenCoins: z.string().nullable().catch(null),
|
|
subsUrl: z.string().nullable().catch(null),
|
|
subsUser: z.string().nullable().catch(null),
|
|
subsPassword: z.string().nullable().catch(null),
|
|
})
|
|
|
|
export const storeJson = FileHelper.json(
|
|
{ base: sdk.volumes.main, subpath: 'store.json' },
|
|
shape,
|
|
)
|