后端迁移会话支撑模块

This commit is contained in:
yml
2026-05-21 15:24:03 +08:00
parent 73b0ee211f
commit 4453f17678
5 changed files with 90 additions and 15 deletions
@@ -0,0 +1,15 @@
import path from 'node:path'
import { fileURLToPath } from 'node:url'
import { runtimeConfig } from '../../config/runtime.js'
import { resolveDefaultViewport } from './session-browser-config.js'
const CURRENT_DIR = path.dirname(fileURLToPath(import.meta.url))
const PROJECT_ROOT = path.resolve(CURRENT_DIR, '../../..')
export const DATA_ROOT = path.resolve(PROJECT_ROOT, 'data/browser-sessions')
export const ACTIVITY_URL = 'https://df.qq.com/cp/a20240812cdk/index.html'
export const CHROME_PATH = String(runtimeConfig.browser.chromePath || '').trim()
export const REDEEM_SUCCESS_AUTO_CLOSE_MS = 3 * 60 * 1000
export const DEFAULT_VIEWPORT = resolveDefaultViewport()
export const SESSION_DEBUG_ENABLED = Boolean(runtimeConfig.session.debug)