diff --git a/packages/backend/src/boot/master.ts b/packages/backend/src/boot/master.ts index 3559816e96..db80dc367a 100644 --- a/packages/backend/src/boot/master.ts +++ b/packages/backend/src/boot/master.ts @@ -90,6 +90,9 @@ export async function masterMain() { maxBreadcrumbs: 0, + // Set release version + release: "Sharkey@" + meta.version, + ...config.sentryForBackend.options, }); } diff --git a/packages/backend/src/boot/worker.ts b/packages/backend/src/boot/worker.ts index 5d4a15b29f..494e7c8c10 100644 --- a/packages/backend/src/boot/worker.ts +++ b/packages/backend/src/boot/worker.ts @@ -9,6 +9,12 @@ import { nodeProfilingIntegration } from '@sentry/profiling-node'; import { envOption } from '@/env.js'; import { loadConfig } from '@/config.js'; import { jobQueue, server } from './common.js'; +import { fileURLToPath } from 'node:url'; +import { dirname } from 'node:path'; +import * as fs from 'node:fs'; +const _filename = fileURLToPath(import.meta.url); +const _dirname = dirname(_filename); +const meta = JSON.parse(fs.readFileSync(`${_dirname}/../../../../built/meta.json`, 'utf-8')); /** * Init worker process @@ -30,6 +36,9 @@ export async function workerMain() { maxBreadcrumbs: 0, + // Set release version + release: "Sharkey@" + meta.version, + ...config.sentryForBackend.options, }); }