Skip to content

Instantly share code, notes, and snippets.

@programarivm
Created July 12, 2020 14:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save programarivm/a9d77b60e73c7e0d15780b3096071bba to your computer and use it in GitHub Desktop.
Save programarivm/a9d77b60e73c7e0d15780b3096071bba to your computer and use it in GitHub Desktop.
wide-open CORS set up
server {
listen 443 ssl;
server_name pgn-chess-data.local;
ssl_certificate /etc/nginx/ssl/pgn-chess-data.local.crt;
ssl_certificate_key /etc/nginx/ssl/pgn-chess-data.local.key;
ssl_ciphers EECDH+AESGCM:EDH+AESGCM:AES256+EECDH:AES256+EDH;
ssl_protocols TLSv1.1 TLSv1.2;
root /usr/share/nginx/pgn-chess-data/public;
client_max_body_size 20M;
location ~ ^/api/ {
try_files $uri /index.php$is_args$args;
}
location ~ ^/.+\.php(/|$) {
fastcgi_pass php_fpm:9000;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment