drupal-with-nginx icon indicating copy to clipboard operation
drupal-with-nginx copied to clipboard

What exactely means @drupal as location in drupal.conf

Open accuraz opened this issue 10 years ago • 1 comments
trafficstars

In the file apps/drupal.conf there is a section called Security measures

The location defined for applying theses Security measures is @drupal, see above

location @drupal {
    ## Include the FastCGI config.
    include apps/drupal/fastcgi_drupal.conf;
    fastcgi_pass phpcgi;

    ## FastCGI microcache.
    include apps/drupal/microcache_fcgi.conf;
    ## FCGI microcache for authenticated users also.
    #include apps/drupal/microcache_fcgi_auth.conf;

    ## If proxying to apache comment the two lines above and
    ## uncomment the two lines below.
    #proxy_pass http://phpapache/index.php?q=$uri;
    #proxy_set_header Connection '';

    ## Proxy microcache.
    #include apps/drupal/microcache_proxy.conf;
    ## Proxy microcache for authenticated users also.
    #include apps/drupal/microcache_proxy_auth.conf;

    ## Filefield Upload progress
    ## http://drupal.org/project/filefield_nginx_progress support
    ## through the NginxUploadProgress modules.
    track_uploads uploads 60s;
}

I don't understand what @drupal location is representing into the filesystem. If it's representing drupal's root directory why just not use / instead of @drupal.

Or maybe I'm on a wrong path with my interpretation of @drupal.

Can someone help me out please ?

Thank you per advance.

accuraz avatar May 05 '15 11:05 accuraz

Hi, The “@” prefix defines a named location. Such a location is not used for a regular request processing, but instead used for request redirection. They cannot be nested, and cannot contain nested locations.

http://nginx.org/en/docs/http/ngx_http_core_module.html#location

hth

xlr5 avatar Jul 17 '15 22:07 xlr5