Closed RainbowDash53 closed 6 years ago
I have exactly the same problem, exactly with this script. CORS means Cross-Origin Resource Sharing. It probably needs to be activated in the nginx container CORS.
docker container ls
(look how your nginx Container is named)
docker exec -i -t azuracast_nginx_1 /bin/sh
vi /etc/nginx/nginx.conf.default
I tried to use this:
https://enable-cors.org/server_nginx.html
The nginx container did not start after this change, unfortunately I no longer have the log.
It may also be that I was in the wrong config file
Maybe someone can help?
Hello,
Simply add add_header Access-Control-Allow-Origin "*";
If doesn't work, send me your full nginx config and the request uri.
Thanks
Thank you very much!
The correct configuration file is:
/etc/nginx/conf.d/azuracast.conf
under server { ...
I added this and restart nginx.
Of course, the configuration will be overwritten at the next update, but so I can at least use CORS (-:
You can map your nginx configuration to host path in docker-compose.yml.
Thanks! My Problem is now:
I just added it in the first section of Server , maybe it´s wrong?
@RainbowDash53 It appears this is a commercial add-on and I'm not sure exactly how it's connecting to the Shoutcast/Icecast server, so I don't know what it's missing as far as access control goes.
The Shoutcast/Icecast servers control their own CORS headers normally. This may be why you're seeing this error, @karndt84, because they're already setting the "*" header and nginx is trying to append to it rather than replace it.
I'd need to see a live demo of this in action to know what's going wrong.
Hello, I missed it's to use with icecast/shoutcast stream. I think it was for the api. Yes shoutcast already inject this header.
@MyTheValentinus As far as I know, AzuraCast sends the proper "Access-Control-Allow-Origin" headers across the application, with GET requests to the API being allowed globally. The Icecast and Shoutcast headers are all set and managed by the software themselves, so they can't necessarily be set by AzuraCast.
If there's some specific change that we need to make on our end, please let me know. Otherwise, I'm assuming this issue is unrelated to our software.
Is your feature request related to a problem? Please describe. I use this: https://codecanyon.net/item/native-flash-radio/9672527/ for my radio but always I've problems with CORS shit (I'm French, I don't understand what is this)
Describe the solution you'd like Could you, add this on a future update? Install SSL in the same time that you install Apache or Ngnix, etc.