From 5909cc8ce1feff51a9a718a4c474c7e34cbc430a Mon Sep 17 00:00:00 2001 From: benweet Date: Sat, 28 Sep 2013 00:41:15 +0100 Subject: [PATCH] Added Node.js static file server --- package.json | 3 +++ server.js | 5 +++++ 2 files changed, 8 insertions(+) create mode 100644 server.js diff --git a/package.json b/package.json index 2e0ad0a6..5b3f4a55 100644 --- a/package.json +++ b/package.json @@ -6,6 +6,9 @@ "directories": { "doc": "doc" }, + "dependencies": { + "express": "3.x" + }, "devDependencies": { "grunt": "~0.4.1", "grunt-contrib-requirejs": "~0.4.1", diff --git a/server.js b/server.js new file mode 100644 index 00000000..e153b7c3 --- /dev/null +++ b/server.js @@ -0,0 +1,5 @@ +var express = require('express'); +var app = express(); +app.use(express.compress()); +app.use(express.static(__dirname)); +app.listen(process.env.PORT || 3000); \ No newline at end of file