forked from Hri7566/mpp-server-dev2
Update WebSocket server; still not serving HTML
This commit is contained in:
parent
f3317c2a0a
commit
d5cfe41c6a
|
@ -1,6 +1,6 @@
|
|||
import env from "~/util/env";
|
||||
import { app } from "~/ws/server";
|
||||
import { Logger } from "~/util/Logger";
|
||||
import env from "./util/env";
|
||||
import { app } from "./ws/server";
|
||||
import { Logger } from "./util/Logger";
|
||||
|
||||
const logger = new Logger("Main");
|
||||
|
||||
|
|
|
@ -5,7 +5,11 @@ import { createUserID } from "../util/id";
|
|||
const logger = new Logger("WebSocket Server");
|
||||
|
||||
export const app = App()
|
||||
.get("/", (res, req) => {})
|
||||
.get("/", (res, req) => {
|
||||
const url = req.getUrl();
|
||||
logger.debug(`${req.getMethod()} ${url} ${req}`);
|
||||
res.writeStatus(`200 OK`).end("HI!");
|
||||
})
|
||||
.ws("/*", {
|
||||
idleTimeout: 30,
|
||||
maxBackpressure: 1024,
|
||||
|
|
Loading…
Reference in New Issue