Scope server routes by base path
This commit is contained in:
@@ -7,14 +7,13 @@
|
||||
# SetEnv CHGRID_HOST_ORIGIN https://example.com
|
||||
|
||||
# Proxy websocket signaling endpoint to local Python service.
|
||||
# `/ws` is used by the browser signaling client for realtime packets.
|
||||
ProxyPass /ws ws://127.0.0.1:8765
|
||||
ProxyPassReverse /ws ws://127.0.0.1:8765
|
||||
# Replace `/chgrid/` with the same value configured in `server.base_path`.
|
||||
ProxyPass /chgrid/ws ws://127.0.0.1:8765/chgrid/ws
|
||||
ProxyPassReverse /chgrid/ws ws://127.0.0.1:8765/chgrid/ws
|
||||
# Proxy auth cookie helper endpoints to local Python service.
|
||||
# These root-scoped paths are required even when the app is hosted under `/chgrid`.
|
||||
# The client calls `/auth/session/set` after login and `/auth/session/clear` on logout/session-reset.
|
||||
ProxyPass /auth/session/ http://127.0.0.1:8765/auth/session/
|
||||
ProxyPassReverse /auth/session/ http://127.0.0.1:8765/auth/session/
|
||||
# These paths should live under the same instance base path.
|
||||
ProxyPass /chgrid/auth/session/ http://127.0.0.1:8765/chgrid/auth/session/
|
||||
ProxyPassReverse /chgrid/auth/session/ http://127.0.0.1:8765/chgrid/auth/session/
|
||||
|
||||
# Ensure HTML entrypoint is never cached so version updates are picked up quickly.
|
||||
<LocationMatch "^/chgrid/?$|^/chgrid/index\\.html$">
|
||||
|
||||
Reference in New Issue
Block a user