Files
spaces-startos/startos/fileModels/storeJson.ts
T
spacesops e41ff31221
Build Service / BuildPackage (push) Has been cancelled
Added optional Explorer/Indexer
2026-05-20 15:43:38 -04:00

35 lines
722 B
TypeScript

import { FileHelper, z } from '@start9labs/start-sdk'
import { sdk } from '../sdk'
const shape = z.object({
password: z.string().nullable().catch(null),
btcAuth: z
.object({
username: z.string(),
password: z.string(),
})
.nullable()
.catch(null),
dbAuth: z
.object({
username: z.string(),
password: z.string(),
database: z.string(),
})
.nullable()
.catch(null),
spacedAuth: z
.object({
username: z.string(),
password: z.string(),
})
.nullable()
.catch(null),
enableExplorer: z.boolean().nullable().catch(null),
})
export const storeJson = FileHelper.json(
{ base: sdk.volumes.main, subpath: 'store.json' },
shape,
)