Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

sample server

  • Loading branch information...
commit f6811dd396f962fd736ad9138d78ea8488a6f38e 1 parent 51c1a58
@tjanczuk authored
Showing with 12 additions and 0 deletions.
  1. +12 −0 sample/server.js
View
12 sample/server.js
@@ -0,0 +1,12 @@
+var http = require('http')
+
+http.createServer(function (req, res) {
+ console.log(new Date() + ': ' + req.url)
+ res.writeHead(200)
+ res.end()
+
+ // do whatever works needs doing here...
+
+}).listen(process.env.PORT || 8000)
+
+console.log('worker listening on http://localhost:' + (process.env.PORT || 8000))
Please sign in to comment.
Something went wrong with that request. Please try again.