diff --git a/config/test.env b/config/test.env index f71f959..73ecf21 100644 --- a/config/test.env +++ b/config/test.env @@ -23,3 +23,6 @@ GIVETH_IO_THIRD_PARTY_MICRO_SERVICE=givethio GIV_ECONOMY_THIRD_PARTY_SECRET=secret GIV_ECONOMY_THIRD_PARTY_MICRO_SERVICE=giveconomy-notification-service + +# OPTIONAL - force logging to stdout when the value is true +LOG_STDOUT=false diff --git a/src/utils/logger.ts b/src/utils/logger.ts index 8d68e41..b0ab1e7 100644 --- a/src/utils/logger.ts +++ b/src/utils/logger.ts @@ -23,7 +23,8 @@ function createBunyanLogger() { if ( process.env.NODE_ENV === 'development' || - process.env.NODE_ENV === 'test' + process.env.NODE_ENV === 'test' || + process.env.LOG_STDOUT === 'true' ) { // Adding logs to console in local machine and running tests bunyanStreams.push({