Permalink
Browse files

* Added specific Drupal headers ignore to fastcgi and proxy.

  • Loading branch information...
1 parent 724bf38 commit 14c8f455a5b2e9de0a2e69460445ce9cbfcdc60a @perusio committed Jun 7, 2011
Showing with 18 additions and 13 deletions.
  1. +5 −1 fastcgi.conf
  2. +1 −1 fastcgi_params
  3. +1 −1 mime.types
  4. +1 −1 nginx.conf
  5. +1 −2 php_fpm_status.conf
  6. +5 −3 reverse_proxy.conf
  7. +1 −1 sites-available/000-default
  8. +1 −1 sites-available/example.com
  9. +1 −1 upstream_phpapache.conf
  10. +1 −1 upstream_phpcgi.conf
View
@@ -1,4 +1,4 @@
-#-*- mode: nginx; mode: flyspell-prog; mode: autopair; ispell-local-dictionary: "american" -*-
+#-*- mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*-
### fastcgi configuration.
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
@@ -7,3 +7,7 @@ fastcgi_intercept_errors on;
## allow 4 hrs - pass timeout responsibility to upstrea
fastcgi_read_timeout 14400;
fastcgi_index index.php;
+## Hide the X-Drupal-Cache header provided by Pressflow.
+fastcgi_hide_header 'X-Drupal-Cache';
+## Hide the Drupal 7 header X-Generator.
+fastcgi_hide_header 'X-Generator';
View
@@ -1,4 +1,4 @@
-# -*- mode: nginx; mode: flyspell-prog; mode: autopair; ispell-local-dictionary: "american" -*-
+# -*- mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*-
### fastcgi parameters.
fastcgi_param QUERY_STRING $query_string;
fastcgi_param REQUEST_METHOD $request_method;
View
@@ -1,4 +1,4 @@
-# -*- mode: nginx; mode: flyspell-prog; mode: autopair; ispell-current-dictionary: american -*-
+# -*- mode: nginx; mode: flyspell-prog; ispell-current-dictionary: american -*-
types {
text/html html htm shtml;
text/css css;
View
@@ -1,4 +1,4 @@
-# -*- mode: nginx; mode: flyspell-prog; mode: autopair; ispell-local-dictionary: "american" -*-
+# -*- mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*-
user www-data;
worker_processes 4;
View
@@ -1,5 +1,4 @@
-# -*- mode: nginx; mode: flyspell-prog; mode: autopair; ispell-current-dictionary: american -*-
-
+# -*- mode: nginx; mode: flyspell-prog; ispell-current-dictionary: american -*-
### The configuration for the status pages of php-fpm. As described in
### http://www.php.net/manual/en/install.fpm.configuration.php.
View
@@ -1,10 +1,12 @@
-# -*- mode: nginx; mode: flyspell-prog; mode: autopair; ispell-local-dictionary: "american" -*-
-
+# -*- mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*-
### Configuration for reverse proxy. Passing the necessary headers to
### the backend. Nginx doesn't tunnel the connection, it opens a new
### one. Hence whe need to send these headers to the backend so that
### the client(s) IP is available to them. The host is also sent.
-
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
+## Hide the X-Drupal-Cache header provided by Pressflow.
+proxy_hide_header 'X-Drupal-Cache';
+## Hide the Drupal 7 header X-Generator.
+proxy_hide_header 'X-Generator';
@@ -1,4 +1,4 @@
-# -*-mode: nginx; mode: flyspell-prog; mode: autopair; ispell-local-dictionary: "american" -*-
+# -*-mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*-
### Block all illegal host headers. Taken from a discussion on nginx
### forums. Cf. http://forum.nginx.org/read.php?2,3482,3518 following
### a suggestion by Maxim Dounin. Also suggested in
@@ -1,4 +1,4 @@
-# -*- mode: nginx; mode: flyspell-prog; mode: autopair; ispell-current-dictionary: american -*-
+# -*- mode: nginx; mode: flyspell-prog; ispell-current-dictionary: american -*-
### Configuration for example.com.
## Rewrite server block.
@@ -1,4 +1,4 @@
-# -*- mode: nginx; mode: flyspell-prog; mode: autopair; ispell-local-dictionary: "american" -*-
+# -*- mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*-
### Upstream configuration for Apache functioning has a PHP handler.
@@ -1,4 +1,4 @@
-# -*- mode: nginx; mode: flyspell-prog; mode: autopair; ispell-local-dictionary: "american" -*-
+# -*- mode: nginx; mode: flyspell-prog; ispell-local-dictionary: "american" -*-
### Upstream configuration for PHP FastCGI.

0 comments on commit 14c8f45

Please sign in to comment.