- NGINX Cookbook
- Tim Butler
- 78字
- 2021-07-03 00:04:24
How to do it...
This recipe is for a basic Drupal configuration, with the Drupal files located in /var/www/html.
Here's the configuration to use:
server { listen 80; server_name drupal.nginxcookbook.com; access_log /var/log/nginx/drupal.access.log combined; index index.php; root /var/www/html/; location / { try_files $uri $uri/ /index.php?$args; } location ~ (^|/)\. { return 403; } location ~ /vendor/.*\.php$ { deny all; return 404; } location ~ \.php$|^/update.php { fastcgi_pass unix:/var/run/php7.0-fpm.sock; fastcgi_split_path_info ^(.+?\.php)(|/.*)$; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME
$document_root$fastcgi_script_name; include fastcgi_params; } }
推薦閱讀
- C++面向對象程序設計(第三版)
- Learning Selenium Testing Tools with Python
- Leap Motion Development Essentials
- 游戲程序設計教程
- Unity 5 for Android Essentials
- Learning Probabilistic Graphical Models in R
- Visual Foxpro 9.0數據庫程序設計教程
- Image Processing with ImageJ
- 編程可以很簡單
- Natural Language Processing with Python Quick Start Guide
- Java程序設計教程
- Elasticsearch搜索引擎構建入門與實戰
- Building a Media Center with Raspberry Pi
- 深入大型數據集:并行與分布化Python代碼
- HTML5+CSS3+jQuery Mobile+Bootstrap開發APP從入門到精通(視頻教學版)