Nginx Boost rules for subdirectory?

Events happening in the community are now at Drupal community events on www.drupal.org.
Rockland Steel's picture

Hello,

I mean subdirectory is:
http://www.domain.tld/ is one Drupal installation, and http://www.domain.tld/app1/ is another Drupal installation.

I use this rules, and still not works:

server {
  listen       80;
  server_name  domain.tld;

  location / {
      root   /var/www;
      index  index.php;

  set $boost "";
  set $boost_query "_";

  if ( $request_method = GET ) {
    set $boost G;
  }

  if ($http_cookie !~ "DRUPAL_UID") {
    set $boost "${boost}D";
  }

  if ($query_string = "") {
    set $boost "${boost}Q";
  }
 
  if ( -f $document_root/cache/normal/$host$request_uri$boost_query.html ) {
    set $boost "${boost}F";
  }

  if ($boost = GDQF){
    rewrite ^.*$ /cache/normal/$host/$request_uri$boost_query.html break;
  }

  if (!-e $request_filename) {
        rewrite ^/app1(/|)(.*)$ /app1/index.php?q=$2 last;
        rewrite  ^/(.*)$  /index.php?q=$1  last;
        break;
      }
  }
}

Thanks

Nginx

Group organizers

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds: