-
-
Notifications
You must be signed in to change notification settings - Fork 26.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add warning when HOST environment variable is set (#3719) #3730
Conversation
Can you please shorten the link? Let's make the second log more along these lines: `Learn more here: ${chalk.yellow('http://bit.ly/2mwWSwH')}` |
if (process.env.HOST) { | ||
console.log( | ||
chalk.yellow( | ||
"Attempting to bind to $HOST because it was specified. If this was unintentional, check that you haven't mistakenly set it in your shell." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't we inline the HOST
value in the message?
Also it's not 100% clear what "$HOST" is. (For example windows uses a different syntax for environment variables.) It is better to explicitly say "environment variable".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What if it was something more like "Attempting to bind to HOST environment variable somehostname.example.com. If this was..."
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM (haven't run it though)
Thanks! |
Looks good! 👍 |
* Add warning when HOST environment variable is set (facebook#3719) * Improve HOST environment variable warning message * Adjust text and message Closes facebook#3719
* Add warning when HOST environment variable is set (facebook#3719) * Improve HOST environment variable warning message * Adjust text and message Closes facebook#3719
To see the new warning message run
HOST=8.8.8.8 npm run start
.Closes #3719