Skip to content

Instantly share code, notes, and snippets.

@TechnoDexx
Last active December 16, 2017 12:19
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 TechnoDexx/207e1a539aad9a79ade96e5db6968f43 to your computer and use it in GitHub Desktop.
Save TechnoDexx/207e1a539aad9a79ade96e5db6968f43 to your computer and use it in GitHub Desktop.
Config files for NGINX (api.autism-support.ru)
server {
listen 80;
root /var/www/platform/httpdocs;
index index.php index.html index.htm index.nginx-debian.html;
server_name api.autism-support.ru;
location / {
try_files $uri $uri/ /index.php$args;
}
location ~ \.php$ {
include snippets/fastcgi-php.conf;
fastcgi_pass unix:/run/php/php7.0-fpm.sock;
}
location ~ /\.ht {
deny all;
}
listen 443 ssl; # managed by Certbot
ssl_certificate /etc/letsencrypt/live/map.autism-support.ru/fullchain.pem; # managed by Certbot
ssl_certificate_key /etc/letsencrypt/live/map.autism-support.ru/privkey.pem; # managed by Certbot
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
if ($scheme != "https") {
return 301 https://$host$request_uri;
} # managed by Certbot
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment