Skip to content

Commit

Permalink
Only log last part of instance id for render
Browse files Browse the repository at this point in the history
  • Loading branch information
nalanj committed Feb 3, 2025
1 parent a0f4a31 commit 900286d
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion packages/utils/lib/logger.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,11 @@ if (!isCloud && !isEnterprise) {
})
];
} else {
const instanceId = isCloud && process.env['RENDER_INSTANCE_ID'] ? ` ${process.env['RENDER_INSTANCE_ID']}` : '';
let instanceId = '';
if (isCloud && process.env['RENDER_INSTANCE_ID']) {
const parts = process.env['RENDER_INSTANCE_ID'].split('-');
instanceId = parts[parts.length - 1] || '';
}

formatters = [
winston.format.printf((info) => {
Expand Down

0 comments on commit 900286d

Please sign in to comment.