Permalink
Browse files

Fixed example in README to bind correct host

  • Loading branch information...
apinnecke committed Feb 1, 2017
1 parent efc13ee commit 97c6e53020da622b006842ef112bc721cac0c47d
Showing with 6 additions and 4 deletions.
  1. +3 −2 README.md
  2. +3 −2 server.js
@@ -15,8 +15,9 @@ a direct visit from the browser.
## Example
```javascript
// Heroku defines the environment variable PORT, and requires the binding address to be 0.0.0.0
var host = process.env.PORT ? '0.0.0.0' : '127.0.0.1';
// Listen on a specific host via the HOST environment variable
var host = process.env.HOST || '0.0.0.0';
// Listen on a specific port via the PORT environment variable
var port = process.env.PORT || 8080;
var cors_proxy = require('cors-anywhere');
@@ -1,5 +1,6 @@
// Heroku defines the environment variable PORT, and requires the binding address to be 0.0.0.0
var host = process.env.PORT ? '0.0.0.0' : '127.0.0.1';
// Listen on a specific host via the HOST environment variable
var host = process.env.HOST || '0.0.0.0';
// Listen on a specific port via the PORT environment variable
var port = process.env.PORT || 8080;
// Grab the blacklist from the command-line so that we can update the blacklist without deploying

0 comments on commit 97c6e53

Please sign in to comment.