Skip to content

Instantly share code, notes, and snippets.

@luizpicolo luizpicolo/server.js
Created Feb 12, 2019

What would you like to do?
const http = require('http');
const port = 3000;
const ip = '';
const server = http.createServer(function(req, res) {
res.writeHead(200, {'Content-Type': 'text/html'});
res.end('<h1>Instituo Federal de Mato Grosso do Sul!</h1>')
server.listen(port, ip, function() {
console.log(`Servidor rodando em http://${ip}:${port}`);
console.log('Para parar o servidor: ctrl + c')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.