🔨 Run once, graceful shutdown, db filename in env
- Refactored toISODateString function - Added Db filename to env - Added getOrDefault function for fetching envs, replaced LOG_LEVEL with getOrDefault - Added script to run job once then exit - Catch SIGINT signal and do a graceful shutdown
This commit is contained in:
@ -5,6 +5,7 @@
|
||||
"main": "index.js",
|
||||
"scripts": {
|
||||
"start": "dotenvx run --env-file=.env.local -- node --import=tsx ./src/main.ts | pino-pretty",
|
||||
"start-once": "ONCE=true dotenvx run --env-file=.env.local -- node --import=tsx ./src/main.ts | pino-pretty",
|
||||
"test": "dotenvx run --env-file=.env.test.local -- node --experimental-vm-modules node_modules/jest/bin/jest.js | pino-pretty",
|
||||
"format": "prettier --write \"./**/*.{js,mjs,ts,md,json}\""
|
||||
},
|
||||
|
Reference in New Issue
Block a user