PlanarAlly can be hosted without effort at a root level (e.g. https://www.planarally.io) or at a subdomain (e.g. https://dnd.planarally.io). When hosting at a subpath however some additional work needs to be done (e.g. https://www.planarally.io/dnd/).
You need to signal to the server that it's running on a subpath. Additionally you might also need to do some changes to your proxy.
When running the PA server, you need to make sure that you set a special environment variable before executing the server.
The above will allow you to run PA on the subpath "/planarally".
When using the docker image, this env variable needs to be passed to the container. Add the following part to your docker command.
Client and dev mode
When building the client it is generally recommended to make sure that the env variable is NOT set during the build.
When running in development mode however, you need to set it for the client as well.
When using nginx, you will have a very similar setup as the one described in proxy, but all
location parts will start with
/planarally if that is your desired subpath.
Additionally you need to make one small modification to the socket.io specific location rule:
The proxy_pass (or host:port pass) needs to be changed to include the subpath. (e.g.
Make sure to setup the proxypass and reverse on the subpath!
ProxyPass /planarally http://127.0.0.1:8000/planarally ProxyPassReverse /planarally http://127.0.0.1:8000/planarally