Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Anchore Engine Chart - Base Url Issue #256

Open
kirkpabk opened this issue Mar 29, 2023 · 1 comment
Open

Anchore Engine Chart - Base Url Issue #256

kirkpabk opened this issue Mar 29, 2023 · 1 comment

Comments

@kirkpabk
Copy link

How does one set the base url to something other than a site root?

So, we have https://apps.somesite.com/anchore. We have many apps under this location, so we can't use https://apps.somesite.com/. We are also using emissary ingress and not the default ingress in the chart. So, how do we tell anchor to use the /anchore path instead?

When we use F12 in the browser, the artifacts with a 404, we can copy the path and insert /anchore/ and the css and js assets get served... so we know the pod is up. There's just some redirect or configuration we're missing. In other apps, there's a uipath or basepath that can be configured to support this. Does this configuration exist for anchore? We tried enabling the chart based ingress and modified the uiPath and apiPath--but this didn't appear to work either.

We have used an emissary policy such as:
apiVersion: getambassador.io/v2
kind: Mapping
.
.
.
name: anchore
namespace: anchore
.
.
.
spec:
bypass_auth: true
host: apps.somesite.com
prefix: /anchore
service: anchore-anchore-engine-enterprise-ui:80
timeout_ms: 300000

We tried using path_redirect: /anchore and path_rewrite: /anchore with no success. We're just not sure where to go next. Any ideas?

@kirkpabk
Copy link
Author

kirkpabk commented Apr 4, 2023

Any answers or insights? @Btodhunter @zhill (Thanks in advance!!)

Our paid support provided the following info:

  • Our app provides all of its assets (the page view initially loaded from the web service and the client assets that are subsequently loaded in order to drive changes in client view state) from an absolute base path. It does this in order to delegate the logical routing of where everything resides to the ingress infrastructure that handles each request. We believe that the app should not make any assertions about its position within a routing scheme as this should be determined by the intermediary—for example, nginx or ambassador—that proxies every request. Customers who want access to the app within a common path can use regex rewrites to substitute the base target path into a common route that contains the prefix of their choosing.

So, my question is still... What is this "absolute base path"? Again, states that we could use a "common path using regex rewrites [in our emissary ingress] to substitute the base target path." Isn't the uiPath values entry supposed to do this for us?

Bottom line, regardless what we try, it seems that the app does not want to honor a web path with a subdirectory of /anchore and only respects a / root.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant