From e3fecd61d05c41135ae9c7c67874c0d816b6c6c0 Mon Sep 17 00:00:00 2001 From: MrFry Date: Sun, 12 Apr 2020 20:37:21 +0200 Subject: [PATCH] Added devel ports --- modules/api/api.js | 1 + server.js | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/modules/api/api.js b/modules/api/api.js index 9042294..3e6e484 100644 --- a/modules/api/api.js +++ b/modules/api/api.js @@ -140,6 +140,7 @@ function GetApp () { const pw = uuidv4() const insertRes = dbtools.Insert(userDB, 'users', { pw: pw, + avaiblePWRequests: 2, created: utils.GetDateString() }) diff --git a/server.js b/server.js index fc52721..344a583 100755 --- a/server.js +++ b/server.js @@ -21,8 +21,13 @@ console.clear() const startHTTPS = true const isRoot = process.getuid && process.getuid() === 0 -const port = isRoot ? 80 : 8080 -const httpsport = 5001 + +let port = isRoot ? 80 : 8080 +let httpsport = isRoot ? 443 : 5001 +if (process.env.NS_DEVEL) { + port = 24243 + httpsport = 24244 +} const express = require('express') const vhost = require('vhost')