mirror of
https://github.com/umami-software/umami.git
synced 2025-12-08 05:12:36 +01:00
Merge dev.
This commit is contained in:
commit
be1b2fc272
88 changed files with 4120 additions and 21010 deletions
|
|
@ -1,27 +0,0 @@
|
|||
/* eslint-disable no-console */
|
||||
require('dotenv').config();
|
||||
|
||||
function checkMissing(vars) {
|
||||
const missing = vars.reduce((arr, key) => {
|
||||
if (!process.env[key]) {
|
||||
arr.push(key);
|
||||
}
|
||||
return arr;
|
||||
}, []);
|
||||
|
||||
if (missing.length) {
|
||||
console.log(`The following environment variables are not defined:`);
|
||||
for (const item of missing) {
|
||||
console.log(' - ', item);
|
||||
}
|
||||
process.exit(1);
|
||||
}
|
||||
}
|
||||
|
||||
if (!process.env.SKIP_DB_CHECK && !process.env.DATABASE_TYPE) {
|
||||
checkMissing(['DATABASE_URL']);
|
||||
}
|
||||
|
||||
if (process.env.CLOUD_MODE) {
|
||||
checkMissing(['CLOUD_URL', 'KAFKA_BROKER', 'KAFKA_URL', 'REDIS_URL', 'KAFKA_SASL_MECHANISM']);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue