diff --git a/operatorapi/proxy.go b/operatorapi/proxy.go
index 51c7f89f7d..835a9dc897 100644
--- a/operatorapi/proxy.go
+++ b/operatorapi/proxy.go
@@ -185,7 +185,8 @@ func serveProxy(responseWriter http.ResponseWriter, req *http.Request) {
responseWriter.WriteHeader(500)
return
}
- targetURL.Path = strings.Replace(req.URL.Path, fmt.Sprintf("/api/proxy/%s/%s", tenant.Namespace, tenant.Name), "", -1)
+ tenantBase := fmt.Sprintf("/api/proxy/%s/%s", tenant.Namespace, tenant.Name)
+ targetURL.Path = strings.Replace(req.URL.Path, tenantBase, "", -1)
proxiedCookie := &http.Cookie{
Name: "token",
@@ -207,8 +208,17 @@ func serveProxy(responseWriter http.ResponseWriter, req *http.Request) {
CheckRedirect: func(req *http.Request, via []*http.Request) error {
return http.ErrUseLastResponse
}}
+
+ // are we proxying something with cp=y? (console proxy) then add cpb (console proxy base) so the console
+ // on the other side updates the