Localhost and 127
Why i cant use localhost but 127.0.0.1 can work?
take a look at your hosts file (location depending on operating system) if there's an entry for localhost.
add 127.0.0.1 localhost to your .host file.
use other ports like localhost:8080, localhost:3036 see if it is working.