CrunchyData / crunchy-katacoda

Other
10 stars 31 forks source link

Allow CORS for local dev environment #72

Closed gsoria closed 4 years ago

gsoria commented 4 years ago

In the local dev environment ngrok is used for referencing the resources under HTTPS, but this has an effect that as the domains differ, we have an error related to Cross-origin resource sharing, for example:

Access to font at 'https://ce150781.ngrok.io/static/fonts/Fort-Medium.ttf' from origin 'https://katacoda.com' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.

This change allows CORS when the environment starts as a development environment.