Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- server {
- listen 80;
- listen [::]:80;
- server_name mydomain;
- return 301 https://$host$request_uri;
- }
- server {
- listen 443 ssl;
- listen [::]:443 ssl;
- server_name mydomain;
- ssl_certificate /etc/letsencrypt/live/mydomain/fullchain.pem;
- ssl_certificate_key /etc/letsencrypt/live/mydomain/privkey.pem;
- ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
- ssl_prefer_server_ciphers on;
- ssl_dhparam /etc/ssl/certs/dhparam.pem;
- ssl_ciphers 'unwichtig';
- ssl_session_timeout 1d;
- ssl_session_cache shared:SSL:50m;
- ssl_stapling on;
- ssl_stapling_verify on;
- add_header Strict-Transport-Security max-age=15768000;
- root /var/www/mydomain;
- index index.php index.html index.htm;
- location / {
- try_files $uri $uri/ =404;
- }
- location ~ \.php$ {
- include snippets/fastcgi-php.conf;
- fastcgi_pass unix:/var/run/php5-fpm.sock;
- }
- location ~ /\.ht {
- deny all;
- }
- location ~ /.well-known {
- allow all;
- }
- }
- server {
- listen 80;
- listen [::]:80;
- server_name pma.mydomain;
- root /var/www/phpmyadmin;
- index index.php index.html index.htm;
- location / {
- try_files $uri $uri/ =404;
- allow 127.0.0.1;
- allow unwichtig;
- allow unwichtig;
- deny all;
- }
- location ~ /robots.txt {
- allow all;
- }
- location ~ \.php$ {
- include snippets/fastcgi-php.conf;
- fastcgi_pass unix:/run/php/php7.0-fpm.sock;
- fastcgi_read_timeout 60;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement