Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
W
weather-on-the-slash
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
open-source
weather-on-the-slash
Commits
797aa6dc
Verified
Commit
797aa6dc
authored
8 years ago
by
Erick Hitter
Browse files
Options
Downloads
Patches
Plain Diff
Allow listener to be configured for use outside of Heroku
parent
95fb7e46
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
config-sample.json
+1
-0
1 addition, 0 deletions
config-sample.json
index.js
+2
-2
2 additions, 2 deletions
index.js
with
3 additions
and
2 deletions
config-sample.json
+
1
−
0
View file @
797aa6dc
{
{
"apikey"
:
""
,
"apikey"
:
""
,
"listener"
:
"0.0.0.0"
,
"port"
:
9001
"port"
:
9001
}
}
This diff is collapsed.
Click to expand it.
index.js
+
2
−
2
View file @
797aa6dc
...
@@ -114,6 +114,6 @@ app.post('/post', function(req, res){
...
@@ -114,6 +114,6 @@ app.post('/post', function(req, res){
});
});
//tells Node which port to listen on
//tells Node which port to listen on
app
.
listen
(
app
.
get
(
'
port
'
),
function
()
{
app
.
listen
(
app
.
get
(
'
port
'
),
config
.
listener
,
function
()
{
console
.
log
(
'
Weather on the Slash is running on port
'
,
app
.
get
(
'
port
'
));
console
.
log
(
'
Weather on the Slash is running on
'
,
config
.
listener
,
'
and
port
'
,
app
.
get
(
'
port
'
)
);
});
});
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment