Attempting to bind HOST environment variable: abc.domain.com
Hi everyone, me again — come back to my stories of bugs.
I got new macbook laptop today, YEAH!
and I was on my way to set up my working environment as well as company’s project on it. then I faced to a proplem as below when I run the project:
`Attempting to bind HOST environment variable: abc.domain.com
If this was unintentional, check that you haven’t mistakenly set it in your shell.
Learn more here: https://cra.link/advanced-config`
After an hour searching for the answer online but still get stuck,
I come to my team leader and ask about it. (If something you dont know and your teammates could help, please don’t hesitate to ask).
The answer is I did not declare the host in /private/etc/hosts
Follow my steps to make it works:
1. Open your terminal, and type sudo vi /private/etc/hosts
this cmd will access/open hosts
file with administrator privilege then you are able to overwrite/edit the file
2. at a line of 127.0.0.1 abc.domain.com
into hosts
file
+ abc.domain.com
is your domain
3. to save the changes, press esc
and :wq
and enter
4. get back to your code editor (VScode), close all terminals, and open new one to run the project again.
I share my experience here with a hope to help someone save there time.
Wish you success.