Intial websocket server creation
This commit is contained in:
parent
5b487b2530
commit
8e95c14b6a
2 changed files with 42 additions and 0 deletions
17
server/src/main.ts
Normal file
17
server/src/main.ts
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
import * as toml from "toml";
|
||||
import { Logger } from "tslog";
|
||||
import { readFileSync } from "fs";
|
||||
import startWebsocket from "./websocket";
|
||||
|
||||
let conf: config = toml.parse(readFileSync(`server.toml`, `utf-8`));
|
||||
|
||||
export const log: Logger = new Logger({
|
||||
displayFunctionName: false,
|
||||
displayLoggerName: false,
|
||||
displayFilePath: `hidden`,
|
||||
displayLogLevel: true,
|
||||
minLevel: conf.log.level,
|
||||
name: conf.log.name,
|
||||
});
|
||||
|
||||
startWebsocket(conf);
|
||||
Loading…
Add table
Add a link
Reference in a new issue