chore: Add NODE_ENV to debug info (#19666)

This commit is contained in:
Marc Littlemore
2025-09-17 16:38:18 +01:00
committed by GitHub
parent 3c1dcfed5b
commit 83181a7c20
7 changed files with 10 additions and 0 deletions

View File

@@ -59,6 +59,7 @@ export interface FrontendSettings {
urlBaseEditor: string;
versionCli: string;
nodeJsVersion: string;
nodeEnv: string | undefined;
concurrency: number;
isNativePythonRunnerEnabled: boolean;
authCookie: {

View File

@@ -129,6 +129,7 @@ export class FrontendService {
urlBaseEditor: instanceBaseUrl,
binaryDataMode: this.binaryDataConfig.mode,
nodeJsVersion: process.version.replace(/^v/, ''),
nodeEnv: process.env.NODE_ENV,
versionCli: N8N_VERSION,
concurrency: this.globalConfig.executions.concurrency.productionLimit,
isNativePythonRunnerEnabled:

View File

@@ -101,6 +101,7 @@ export const defaultSettings: FrontendSettings = {
},
versionCli: '',
nodeJsVersion: '',
nodeEnv: '',
concurrency: -1,
isNativePythonRunnerEnabled: false,
versionNotifications: {

View File

@@ -8,6 +8,7 @@ exports[`useDebugInfo > should generate debug info 1`] = `
- n8nVersion: 0.123.0
- platform: docker (cloud)
- nodeJsVersion: 14.17.0
- nodeEnv: production
- database: postgres
- executionMode: regular
- concurrency: 10

View File

@@ -14,6 +14,7 @@ const MOCK_BASE_SETTINGS: RecursivePartial<ReturnType<typeof useSettingsStoreTyp
isDocker: true,
deploymentType: 'cloud',
nodeJsVersion: '14.17.0',
nodeEnv: 'production',
databaseType: 'postgresdb',
isQueueModeEnabled: false,
settings: {

View File

@@ -8,6 +8,7 @@ type DebugInfo = {
n8nVersion: string;
platform: 'docker (cloud)' | 'docker (self-hosted)' | 'npm';
nodeJsVersion: string;
nodeEnv: string | undefined;
database: 'sqlite' | 'mysql' | 'mariadb' | 'postgres';
executionMode: 'regular' | 'scaling (single-main)' | 'scaling (multi-main)';
license: 'community' | 'enterprise (production)' | 'enterprise (sandbox)';
@@ -58,6 +59,7 @@ export function useDebugInfo() {
? 'docker (self-hosted)'
: 'npm',
nodeJsVersion: settingsStore.nodeJsVersion,
nodeEnv: settingsStore.nodeEnv,
database:
settingsStore.databaseType === 'postgresdb'
? 'postgres'

View File

@@ -68,6 +68,8 @@ export const useSettingsStore = defineStore(STORES.SETTINGS, () => {
const nodeJsVersion = computed(() => settings.value.nodeJsVersion);
const nodeEnv = computed(() => settings.value.nodeEnv);
const concurrency = computed(() => settings.value.concurrency);
const isNativePythonRunnerEnabled = computed(() => settings.value.isNativePythonRunnerEnabled);
@@ -331,6 +333,7 @@ export const useSettingsStore = defineStore(STORES.SETTINGS, () => {
pruning,
security,
nodeJsVersion,
nodeEnv,
concurrency,
isNativePythonRunnerEnabled,
isConcurrencyEnabled,