From b09bad1e14f733d5e60f11270df19b92f5714473 Mon Sep 17 00:00:00 2001 From: Gowri Sankar Date: Fri, 31 May 2024 13:13:36 +0930 Subject: [PATCH] DO-1666: update gitignore --- packages/prerender-fargate/.gitignore | 2 +- .../lib/prerender/utils/logger.js | 20 +++++++++++++++++++ 2 files changed, 21 insertions(+), 1 deletion(-) create mode 100644 packages/prerender-fargate/lib/prerender/utils/logger.js diff --git a/packages/prerender-fargate/.gitignore b/packages/prerender-fargate/.gitignore index ec769510..14559189 100644 --- a/packages/prerender-fargate/.gitignore +++ b/packages/prerender-fargate/.gitignore @@ -1 +1 @@ -!lib/prerender/* +!lib/prerender/** diff --git a/packages/prerender-fargate/lib/prerender/utils/logger.js b/packages/prerender-fargate/lib/prerender/utils/logger.js new file mode 100644 index 00000000..61e3d599 --- /dev/null +++ b/packages/prerender-fargate/lib/prerender/utils/logger.js @@ -0,0 +1,20 @@ +"use strict"; + +const pino = require("pino"); + +module.exports = pino({ + base: undefined, + timestamp: false, + messageKey: "message", + customLevels: { + render: 35, + }, + level: process.env.LOG_LEVEL || "info", + formatters: { + level: label => { + return { + level: label, + }; + }, + }, +});