-
-
Save arx76/edfa68f4ec3b4072be2cb38758d76b83 to your computer and use it in GitHub Desktop.
Diretiva Nginx para usar Laravel e ISPConfig3
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| location = /robots.txt { | |
| root {DOCROOT}public; | |
| access_log off; | |
| log_not_found off; | |
| allow all; | |
| } | |
| location / { | |
| root {DOCROOT}public; | |
| try_files $uri $uri/ /index.php?q=$uri&$args; | |
| #Para desativar o site comentar a linha acima e habilitar esta baixo | |
| #return 503 "Servico Indisponivel"; | |
| } | |
| add_header X-Frame-Options "SAMEORIGIN"; | |
| add_header X-XSS-Protection "1; mode=block"; | |
| add_header X-Content-Type-Options "nosniff"; | |
| error_page 404 /index.php; | |
| location @php { | |
| try_files $uri =404; | |
| root {DOCROOT}public; | |
| include /etc/nginx/fastcgi_params; | |
| fastcgi_pass unix:/var/lib/php7.1-fpm/web14.sock; ## Alterar usuario web14 conforme sua aplicação e a versão do PHP caso necessário | |
| fastcgi_index index.php; | |
| fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; | |
| fastcgi_intercept_errors off; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment