Skip to content

Instantly share code, notes, and snippets.

@jack80342
Last active April 19, 2023 02:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jack80342/64b4a2700ee59d4911dfe3ca4f335c93 to your computer and use it in GitHub Desktop.
Save jack80342/64b4a2700ee59d4911dfe3ca4f335c93 to your computer and use it in GitHub Desktop.
const http = require('http');
const os = require('OS');
console.log("Kubi a server starting ... ");
var handler = function(request, response);
console.log("Received request from " + request.connection.remoteAddress);
response.writeHead(200);
response.end("You've hit " + os.hostname() + "\n" );
var www = http.createServer(handler);
www.listen(8080);
FROM node:7
ADD app.js /app.js
ENTRYPOINT ["node","app.js"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment