I'm attempting to set up Apache to reverse proxy a Tensorboard server so I can view training progress over the web at my website,
example.com. I decided to mess with two ways of implementing this: 1) creating a subdomain
log.example.com and having Apache pass requests to this domain through to the server or 2) simply having Apache reverse proxy the server when
example.com/tensorboard is visited. After testing both, only the first approach appears to work correctly.
The Tensorboard server is running on port 6006 of my server machine. Here are my Apache config files for the aforementioned approaches:
1) using the subdomain
<VirtualHost *:80> ServerName log.example.com ProxyPreserveHost On <Directory /path/to/needed/files> Require all granted </Directory> ProxyPass / http://127.0.0.1:6006/ ProxyPassReverse / http://127.0.0.1:6006/ </VirtualHost>
This works as expected. The Tensorboard server loads and displays graphs correctly.
<VirtualHost *:80> ServerName example.com ProxyPreserveHost On <Directory /path/to/needed/files> Require all granted </Directory> <Location /tensorboard> ProxyPass http://127.0.0.1:6006/ ProxyPassReverse http://127.0.0.1:6006/ </Location> </VirtualHost>
This does not work as expected. A template page does load from Tensorboard, but it never gets any further than that; it's always stuck attempting to load any of the expected graphs.
Because the first method works, I assume the problem doesn't lie with my Tensorboard server. I can't understand why both of these approaches don't work the exact same way; any ideas on what's going wrong with my second approach here?