My Codeigniter package connected with Cloudflare. If my package connected with Cloudflare. It's not working and it shows "Error 520: Web server is returning an unknown error".
Without Cloudflare it's working fine.
My Codeigniter package connected with Cloudflare. If my package connected with Cloudflare. It's not working and it shows "Error 520: Web server is returning an unknown error".
Without Cloudflare it's working fine.
I'd like to add my fix for my 520 issue with Cloudflare. I had a content security policy set up on my nginx server configuration in nginx.conf.
add_header Content-Security-Policy "default-src 'self' https://www.google-analytics.com ;
img-src 'self' https://*.ggpht.com ;
I had inserted a line break into this header and never noticed or cared because it worked on all browsers. Removing my line breaks to look like the below resolved my issues.
add_header Content-Security-Policy "default-src 'self' https://www.google-analytics.com ; img-src 'self' https://*.ggpht.com ;
You probably won't run into the exact issue as me, but the lesson here is to check your headers and try to selectively remove them until you can isolate or rule out these as issues. Hopefully this can save you $20 for a cloudflare support subscription.