Created
August 26, 2015 20:45
-
-
Save maximkoretskiy/21fb222718fed62b8dc6 to your computer and use it in GitHub Desktop.
small server
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
var express = require('express'); | |
var app = express(); | |
var port = process.env.PORT || 5000 | |
app.use(express.static(__dirname + "/dist")) | |
var server = app.listen(port, function () { | |
var host = server.address().address; | |
var port = server.address().port; | |
console.log('Example app listening at http://%s:%s', host, port); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment