Skip to content

Commit 4267468

Browse files
committed
look for port in process.env, otherwise default to 8080
1 parent d9a643f commit 4267468

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

jekyll-hook.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -82,8 +82,9 @@ app.post('/hooks/jekyll/:branch', function(req, res) {
8282
});
8383

8484
// Start server
85-
app.listen(8080);
86-
console.log('Listening on port 8080');
85+
var port = process.env.PORT || 8080;
86+
app.listen(port);
87+
console.log('Listening on port ' + port);
8788

8889
function run(file, params, cb) {
8990
var process = spawn(file, params);

0 commit comments

Comments
 (0)