mirror of
https://github.com/Lifeforge-app/lifeforge.git
synced 2026-06-28 06:46:24 +00:00
fix(db): Implement Pocketbsse http kwargs for accurate database startup
This commit is contained in:
@@ -26,10 +26,14 @@ export const PB_BINARY_PATH = path.resolve(
|
||||
process.env.PB_BINARY_PATH || `${PB_DIR}/pocketbase`
|
||||
)
|
||||
|
||||
// Remove http:// prefix if present
|
||||
export const PB_HOST = getEnvVar('PB_HOST').replace(/^http:\/\//, '')
|
||||
|
||||
export const PB_KWARGS = [
|
||||
`--dir=${PB_DATA_DIR}`,
|
||||
`--migrationsDir=${PB_MIGRATIONS_DIR}`,
|
||||
'--automigrate=0'
|
||||
'--automigrate=0',
|
||||
`--http ${PB_HOST || 'localhost:8090'}`
|
||||
]
|
||||
|
||||
// Straightaway exit if PB_DIR is not accessible (skip in Docker mode)
|
||||
|
||||
Reference in New Issue
Block a user