From 76892fba168f967e27012279f751e5cf4c5593ce Mon Sep 17 00:00:00 2001 From: Matias Korhonen Date: Wed, 26 May 2010 16:46:30 +0300 Subject: [PATCH] Fixes the nginx #send_file configuration example. --- lib/rack/sendfile.rb | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/rack/sendfile.rb b/lib/rack/sendfile.rb index e94ee08..68c7df8 100644 --- a/lib/rack/sendfile.rb +++ b/lib/rack/sendfile.rb @@ -31,19 +31,19 @@ module Rack # a private "/files/" area, enable X-Accel-Redirect, and pass the special # X-Sendfile-Type and X-Accel-Mapping headers to the backend: # - # location /files/ { + # location ~ /files/(.*) { # internal; - # alias /var/www/; + # alias /var/www/$1; # } # # location / { - # proxy_redirect false; + # proxy_redirect off; # # proxy_set_header Host $host; # proxy_set_header X-Real-IP $remote_addr; # proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; # - # proxy_set_header X-Sendfile-Type X-Accel-Redirect + # proxy_set_header X-Sendfile-Type X-Accel-Redirect; # proxy_set_header X-Accel-Mapping /files/=/var/www/; # # proxy_pass http://127.0.0.1:8080/; -- 1.6.6.1