From 122f2a5e8db2de2beb1bed90e17ccb5c022e14b6 Mon Sep 17 00:00:00 2001 From: Benjamin Kraft Date: Mon, 14 Nov 2022 20:55:42 +0100 Subject: [PATCH] server test change --- src/index.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/index.ts b/src/index.ts index dc66877..3e3007b 100644 --- a/src/index.ts +++ b/src/index.ts @@ -7,14 +7,14 @@ import {ConnectionManager} from "./manager"; import https = require('https'); import {Server} from 'socket.io'; import fs = require('fs'); -import ini = require('ini'); export function GameServer(){ const p2p = require('socket.io-p2p-server').Server; let rootDir = __dirname + '/..'; - let httpsPort = ini.parse(fs.readFileSync(rootDir + '/env_config.ini', 'utf-8'))['nodejs_port']; + require("dotenv").config(); + const httpsPort = process.env["https_port"]; let cert = fs.readFileSync(rootDir + '/ssl_certificate/cert.pem'); let key = fs.readFileSync(rootDir + '/ssl_certificate/key.pem');