Added version to config

This commit is contained in:
Nicolai Ort 2021-01-30 17:25:36 +01:00
parent ae466b4d7e
commit b1747f6374

View File

@ -3,7 +3,8 @@ import { config as configDotenv } from 'dotenv';
configDotenv(); configDotenv();
export const config = { export const config = {
internal_port: parseInt(process.env.APP_PORT) || 4010, internal_port: parseInt(process.env.APP_PORT) || 4010,
development: process.env.NODE_ENV === "production" development: process.env.NODE_ENV === "production",
version: process.env.VERSION || require('../package.json').version,
} }
let errors = 0 let errors = 0
if (typeof config.internal_port !== "number") { if (typeof config.internal_port !== "number") {