summaryrefslogtreecommitdiff
path: root/source/index.ts
diff options
context:
space:
mode:
Diffstat (limited to 'source/index.ts')
-rw-r--r--source/index.ts7
1 files changed, 7 insertions, 0 deletions
diff --git a/source/index.ts b/source/index.ts
index e22478e..dac1b2d 100644
--- a/source/index.ts
+++ b/source/index.ts
@@ -12,6 +12,8 @@ const render_env = {
commit: readFileSync(join(__dirname, "../.git/refs/heads/main")).toString().substr(0, 8)
}
+app.disable('x-powered-by');
+
app.set("view engine", "pug")
app.set("views", join(__dirname, "../views"))
@@ -26,6 +28,11 @@ app.get("/licence", async (req, res) => {
res.type("text/plain").send(content)
})
+app.get("/favicon.ico", (req,res) => res.sendStatus(204)) // no content
+app.get("/robots.txt", (req,res) => {
+ res.send("User-Agent: *\nDisallow: /")
+})
+
const PORT = parseInt(process.env.PORT ?? "8080")
const HOST = process.env.HOST || "127.0.0.1"