4 ms·
URLs already have default ports for service names as a feature. http:// means port 80 unless specified otherwise https:// means port 443 unless specified othe
by qurren 6mo ago
URLs already have default ports for service names as a feature.
http:// means port 80 unless specified otherwise
https:// means port 443 unless specified otherwise
ftp:// means port 21 unless specified otherwise
sftp:// means port 22 unless specified otherwise
...
The practical solution for TFA is actually just an nginx server running on port 80 with proxy_pass
location /blog/ {
proxy_pass http://127.0.0.1:3000 ;
}
location /tensorboard/ {
proxy_pass http://127.0.0.1:6006;
}
...
- jameshart 6mo agoHow many little web servers work without issue when their root page is loaded from a path other than /?
- qurren 6mo agoIf that's your concern you can also do this server { listen 80; server_name "tensorboard.localhost"; location / { proxy_pass http://127.0.0.1:6006; } } server { listen 80; server_name "blog.localhost"; location / { proxy_pass http://127.0.0.1:3000; } } HTTP 1.1 and later will have the browser supply the domain name that was used to access the site, and even though *.localhost all resolve to 127.0.0.1, nginx will pluck out the correct configuration and proxy_pass the correct one.
- halJordan 6mo agoThat's because there defines in etc services (really the place where etc services gets its mapping). You're putting the cart in front of the horse