feat: set default session retention to 7 days (#565)

This commit is contained in:
paisley
2026-03-18 11:10:05 +08:00
committed by GitHub
Unverified
parent e94629e5c8
commit 5a657130c9
2 changed files with 46 additions and 1 deletions

View File

@@ -9,7 +9,7 @@ import { getProviderEnvVar, getKeyableProviderTypes } from '../utils/provider-re
import { getOpenClawDir, getOpenClawEntryPath, isOpenClawPresent } from '../utils/paths';
import { getUvMirrorEnv } from '../utils/uv-env';
import { listConfiguredChannels } from '../utils/channel-config';
import { syncGatewayTokenToConfig, syncBrowserConfigToOpenClaw, sanitizeOpenClawConfig } from '../utils/openclaw-auth';
import { syncGatewayTokenToConfig, syncBrowserConfigToOpenClaw, syncSessionIdleMinutesToOpenClaw, sanitizeOpenClawConfig } from '../utils/openclaw-auth';
import { buildProxyEnv, resolveProxySettings } from '../utils/proxy';
import { syncProxyConfigToOpenClaw } from '../utils/openclaw-proxy';
import { logger } from '../utils/logger';
@@ -152,6 +152,12 @@ export async function syncGatewayConfigBeforeLaunch(
} catch (err) {
logger.warn('Failed to sync browser config to openclaw.json:', err);
}
try {
await syncSessionIdleMinutesToOpenClaw();
} catch (err) {
logger.warn('Failed to sync session idle minutes to openclaw.json:', err);
}
}
async function loadProviderEnv(): Promise<{ providerEnv: Record<string, string>; loadedProviderKeyCount: number }> {