Advertisement
Guest User

Untitled

a guest
Sep 6th, 2018
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Nginx 1.26 KB | None | 0 0
  1. server {
  2.     root /var/www/html;
  3.  
  4.     index index.php index.html index.htm index.nginx-debian.html;
  5.  
  6.     server_name eliseorobles.me www.eliseorobles.me;
  7.  
  8.     location / {
  9.         try_files $uri $uri/ =404;
  10.     }
  11.  
  12.     location ~ \.php$ {
  13.         include snippets/fastcgi-php.conf;
  14.         fastcgi_pass unix:/run/php/php7.0-fpm.sock;
  15.     }
  16.  
  17.     location ~ /\.ht {
  18.         deny all;
  19.     }
  20.  
  21.     listen [::]:443 ssl ipv6only=on; # managed by Certbot
  22.     listen 443 ssl; # managed by Certbot
  23.     ssl_certificate /etc/letsencrypt/live/eliseorobles.me/fullchain.pem; # manag ed by Certbot
  24.     ssl_certificate_key /etc/letsencrypt/live/eliseorobles.me/privkey.pem; # man aged by Certbot
  25.     include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
  26.     ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
  27. }
  28.  
  29. server {
  30.     if ($host = www.eliseorobles.me) {
  31.         return 301 https://$host$request_uri;
  32.     } # managed by Certbot
  33.  
  34.  
  35.     if ($host = eliseorobles.me) {
  36.         return 301 https://$host$request_uri;
  37.     } # managed by Certbot
  38.  
  39.  
  40.     listen 80 default_server;
  41.     listen [::]:80 default_server;
  42.  
  43.     server_name eliseorobles.me www.eliseorobles.me;
  44.     return 404; # managed by Certbot
  45. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement