apache / apisix-dashboard

Dashboard for Apache APISIX
https://apisix.apache.org/
Apache License 2.0
974 stars 517 forks source link

Receiving the error - Refused to execute script because X-Content-Type-Options: nosniff was given and Content-Type is not a script MIME type #2893

Open anandasastry opened 9 months ago

anandasastry commented 9 months ago

Issue description

My APISIX Dashboard is behind a load balancer VIP and the VIP automatically add the below header in the server response

X-Content-Type-Options: nosniff

Because of this, the browser is not able to execute the javascript as the Content-Type being set by the Dashboard application is text/html instead of text/javascript.

How to resolve this issue?

Expected behavior

View APISIX Dashboard Login page

How to Reproduce

Place APISIX Dashboard behind a load balancer vip and configure the vip to add the below header in the response

X-Content-Type-Options: nosniff

Screenshots

No response

Environment

Additional context

No response

YevhenLL commented 2 months ago

Bug is still present.