Initial commit

This commit is contained in:
2024-11-12 23:37:34 -05:00
commit ab5907355d
4 changed files with 565 additions and 0 deletions

22
src/main.ts Normal file
View File

@@ -0,0 +1,22 @@
import Logging from "log-like-a-zombie";
import express from "express";
const log = new Logging("Main");
const port = 3000;
const address = "127.0.0.1";
log.i(`Starting HTTP server on http://${address}:${port}`);
const app = express();
app.disable('etag');
app.disable('x-powered-by');
app.use((rq: express.Request, rs: express.Response) => {
log.n(`${rq.ip} ${rq.method} ${rq.originalUrl}`);
rs.sendStatus(200);
});
app.listen(port, address, () => {
log.i(`Listening on http://${address}:${port}`);
});