Newbie1
3 years agoOccasional Contributor
Swagger behind Nginx Proxy and CORS error
Hi all!
I have a problem. I would like to not get an CORS error after pasting in swagger available under swagger.example.com the link to the file available under testing.example.com/plik.yaml. The vhost file: https://pastebin.com/KXTv7CBm I am using. The commented out location block was my second attempt. After that I already started combining with different configurations from the net, but with no effect.
PS
I wonder if it is possible to make proxy + cors configured on swagger.example.com in such a way, that I do not have to add:
PS
I wonder if it is possible to make proxy + cors configured on swagger.example.com in such a way, that I do not have to add:
add_header Access-Control-Allow-Origin "https://swagger.example.com";
on every server which will use swagger available under swagger.example.com. Do any of you guys have any ideas?