Last active
July 14, 2022 19:09
-
-
Save nairihar/e19842082d9510dfc6fef41a2a851ea8 to your computer and use it in GitHub Desktop.
Scaling up Node.js Socket Server with Nginx and Redis | server.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const express = require('express'); | |
const app = express(); | |
app.get('/', (req, res) => { | |
res.end(`Hi, PID: ${process.pid}`); | |
}); | |
app.listen(process.env.PORT); | |
console.log(`Server running on ${process.env.PORT} port, PID: ${process.pid}`); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment