Open tomwilkie opened 5 years ago
Hey @tomwilkie. Thank you for your feedback. I thought AJAX fetches would work with relative paths; at least that's how I intended it to work. Might be a bug. I'll follow up on this later.
Thanks @sergiitk! Looks like they're using absolute URLs: https://github.com/sergiitk/pagerbeauty/blob/e217a7991b7883312f4ab4a5dab86153d4d61c7c/src/assets/javascripts/ui-pagerbeauty.jsx#L32
Is your feature request related to a problem? Please describe.
I'd like to run pagerbeauty and serve is form a subpath (ie /pagerbeauty). We have a single https endpoint for tools, with an nginx forwarding various subpaths to those. This allows us to do access control centrally.
Describe the solution you'd like
An env var
PAGERBEAUTY_HTTP_PATH=/pagerbeauty
Describe alternatives you've considered
I've tried having the nginx do all the rewrites in front of pagerbeauty, and got quite far - the redirect, the embedded scripts and styles etc. But the AJAX fetch of schedules.json is too much for a nginx rewrite.