Advertisement
puncoz

abroadprep.com.conf

Jun 19th, 2018
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. server {
  2.         listen 80;
  3.         listen [::]:80 ipv6only=on;
  4.  
  5.         # SSL configuration
  6.         #
  7.         # listen 443 ssl default_server;
  8.         # listen [::]:443 ssl default_server;
  9.         #
  10.         # Note: You should disable gzip for SSL traffic.
  11.         # See: https://bugs.debian.org/773332
  12.         #
  13.         # Read up on ssl_ciphers to ensure a secure configuration.
  14.         # See: https://bugs.debian.org/765782
  15.         #
  16.         # Self signed certs generated by the ssl-cert package
  17.         # Don't use them in a production server!
  18.         #
  19.         # include snippets/snakeoil.conf;
  20.  
  21.         #root /var/www/html;
  22.         root /home/wordpress/web/public;
  23.  
  24.         # Add index.php to the list if you are using PHP
  25.         index index.php index.html index.htm index.nginx-debian.html;
  26.  
  27.         #server_name 173.255.208.85;
  28.         server_name abroadprep.com www.abroadprep.com;
  29.  
  30.         location = /favicon.ico { log_not_found off; access_log off; }
  31.         location = /robots.txt { log_not_found off; access_log off; allow all; }
  32.         location ~* \.(css|gif|ico|jpeg|jpg|js|png)$ {
  33.                 expires max;
  34.                 log_not_found off;
  35.         }
  36.  
  37.         location / {
  38.                 # First attempt to serve request as file, then
  39.                 # as directory, then fall back to displaying a 404.
  40.                 #try_files $uri $uri/ =404;
  41.                 #try_files $uri $uri/ /index.php?$query_string;
  42.                 try_files $uri $uri/ /index.php$is_args$args;
  43.         }
  44.  
  45.         # pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
  46.         #
  47.         location ~ \.php$ {
  48.                 include snippets/fastcgi-php.conf;
  49.  
  50.                 fastcgi_split_path_info ^(.+\.php)(/.+)$;
  51.                 # With php7.0-cgi alone:
  52.         #       fastcgi_pass 127.0.0.1:9000;
  53.                 # With php7.0-fpm:
  54.                 fastcgi_pass unix:/run/php/php7.1-fpm-wordpress.sock;
  55.                 fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
  56.                 include fastcgi_params;
  57.         }
  58.  
  59.         # deny access to .htaccess files, if Apache's document root
  60.         # concurs with nginx's one
  61.         #
  62.         location ~ /\.ht {
  63.                 deny all;
  64.         }
  65.  
  66.     listen 443 ssl; # managed by Certbot
  67. ssl_certificate /etc/letsencrypt/live/www.abroadprep.com/fullchain.pem; # managed by Certbot
  68. ssl_certificate_key /etc/letsencrypt/live/www.abroadprep.com/privkey.pem; # managed by Certbot
  69.     include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
  70.     ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
  71.  
  72.  
  73. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement