Documentation on how to add a host address #26
-
Hello, When I run the following from my terminal, I can see my project at
Is there any way I can also load
What should be my next steps? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Great question! The hosts file entry gets you part of the way there by mapping If you leave the port at the default of "5080" then you should be able to hit the site at The other option is to change the default port for the Statiq preview server to the default HTTP port 80 so that you don't need to specify one. This gets tricky because there's a chance you have something else bound to port 80 on your system (and only one process can bind to a port at a time). Try Also, for what it's worth, the Statiq preview server is entirly built-in (it's an in-process Kestrel server). You don't need to worry about your IIS Express instance unless you want to serve your output folder through IIS. |
Beta Was this translation helpful? Give feedback.
Great question! The hosts file entry gets you part of the way there by mapping
local.statiq
to your local network. The other part is going to be the port that the Statiq preview server is listening on.If you leave the port at the default of "5080" then you should be able to hit the site at
http://local.statiq:5080
. Since DNS resolution (the hosts file bit) and binding a TCP listener to a port are separate things, there's unfortunately no way to add the port to the hosts file.The other option is to change the default port for the Statiq preview server to the default HTTP port 80 so that you don't need to specify one. This gets tricky because there's a chance you have something else bound…