Reverse proxy cockpit, but leave URL Root as / for local accces #20121
Unanswered
chriswiggins
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
We are looking into deploying cockpit on many servers, where we want to access them either via a reverse proxy or locally.
I have been through commit 8e4958a to understand where the
UrlRoot
parameter comes from, but I'm trying to understand why this is hard-coded? Can't all the pathing etc to the cockpit endpoint just be relative?Ideally we would like to dynamically reverse-proxy through our own middleware, whereby the server being accessed needs to have no knowledge of the URL that it is getting accessed through.
We do this in many other instances already, where an example nginx config looks something like this (note the forward slashes):
Perhaps I'm missing something, but is there a reason Cockpit doesn't support relative paths? Happy to open a PR changing this, just need to be pointed in the right direction!
Alternatively, would there be interest in supporting a header which tells cockpit which URL it is being served from?
Thanks, Chris
Beta Was this translation helpful? Give feedback.
All reactions