server { listen 80 default_server; listen [::]:80 default_server ipv6only=on; root /var/www/myproject/public; index index.php index.html index.htm; server_name nthere is my domain; return 301 https://$server_name$request_uri; location / { try_files $uri $uri/ /index.php?$query_string; } location ~ \.php$ { include snippets/fastcgi-php.conf; fastcgi_pass unix:/run/php/php7.2-fpm.sock; } location ~ /\.ht { deny all; } } server { listen 443 ssl http2 default_server; listen [::]:443 ssl http2 default_server ipv6only=on; root /var/www/myproject/public; index index.php index.html index.htm;
Обсуждают сегодня