UNPKG

916 BJavaScriptView Raw
1"use strict";
2Object.defineProperty(exports, "__esModule", { value: true });
3/**
4 * Project Configuration.
5 *
6 * NOTE: All file/folder paths should be relative to the project root. The
7 * absolute paths should be resolved during runtime by our build internal/server.
8 */
9const envVars = require("@erect/config/envVars");
10const listenAddress = envVars.string('LISTEN_ADDRESS', '0.0.0.0');
11const listenPort = envVars.number('LISTEN_PORT', 1337);
12let host;
13if (typeof process.env.HOST === 'undefined') {
14 if (listenAddress === '0.0.0.0' || listenAddress === '127.0.0.1') {
15 host = 'localhost';
16 }
17 else {
18 host = listenAddress;
19 }
20 if (listenPort !== 80) {
21 host = `${host}:${listenPort}`;
22 }
23}
24else {
25 host = process.env.HOST;
26}
27exports.defaultValues = {
28 listenAddress,
29 listenPort,
30 host,
31 disableSubscription: false,
32};
33//# sourceMappingURL=defaultValues.js.map
\No newline at end of file