canonical / maas-ui

The UI for MAAS (metal-as-a-service)
https://maas.io
Other
49 stars 48 forks source link

Sentry blocked by CORS #4535

Closed petermakowski closed 1 year ago

petermakowski commented 1 year ago

Describe the bug

Sentry requests are being blocked by CORS policy.

Steps to reproduce

  1. Go to http://polong.internal:5240/MAAS/r/machines
  2. Open Developer tools
  3. The error below is being thrown in the console:

Access to fetch at 'https://sentry.is.canonical.com/api/22/envelope/?sentry_key=901f18f8af164718b5cb34c869e6885d&sentry_version=7&sentry_client=sentry.javascript.browser%2F7.8.0' from origin 'http://polong.internal:5240' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.

maas-ui version 3.3.0

Additional context We might need to use a tunnel to workaround this: https://docs.sentry.io/platforms/javascript/troubleshooting/#using-the-tunnel-option

petermakowski commented 1 year ago

This is under investigation by IS https://rt.admin.canonical.com/Ticket/Display.html?id=136334