dgf-prototype/backend/src/index.js

21 lines
339 B
JavaScript

require('dotenv').config();
const api = require('./api');
const matrixBot = require('./matrix-bot');
const eventHandlers = require('./event-handlers');
const {
ENABLE_API,
ENABLE_MATRIX,
} = process.env;
if (ENABLE_API !== 'false') {
api.start();
}
if (ENABLE_MATRIX !== 'false') {
matrixBot.start();
}
eventHandlers.start();