Strapi Version: 4.7.0
Operating System: Windows 10
Node Version: 16.19.1
NPM Version: 8.19.3
When executing the command:
NODE_ENV=production npm run start to start server with production settings, it seems to work fine with little errors, and the following message displays:
One more thing…
Create your first administrator by going to the administration panel at:
│ http://0.0.0.0:1337/admin │
However, when navigating to this url, the browser does not load the page. Instead, it displays the error message:
This site can’t be reached
The web page at http://0.0.0.0:1337/admin might be temporarily down or it may have moved permanently to a new web address.
0.0.0.0 is not the same as local host
0.0.0.0 should be
Just to expand on this answer.
0.0.0.0 means any IP, while the most significant difference between localhost and 127.0. 0.1 is that there is a need to have a lookup table in case of localhost, while in 127.0. 0.1, we do not need to look up a table somewhere .
Thank you both. I used the code snippets from the documentation which is why I have used 0.0.0.0 as part of the host variable.
After changing the APP_HOST/HOST value in the
.env file (which contains the environment variables), after rebuilding the server using the command
NODE_ENV=production npm run build and after restarting the server by executing the command
NODE_ENV=production npm run start, the following message displays:
One more thing...
Create your first administrator 💻 by going to the administration panel at:
│ http://127.0.0.1:1337/admin │
This time, when navigating to this url, the browser successfully loads the Strapi Admin page at the link: