Created
January 14, 2010 05:05
-
-
Save actsasflinn/276891 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# nginx with memcache module... after a request the connection to memcached closes, what gives? | |
http { | |
upstream memcache { | |
server 127.0.0.1:11211; | |
keepalive 1024 single; # with this or without http://mdounin.ru/hg/ngx_http_upstream_keepalive/ | |
} | |
server { | |
listen 80; | |
server_name localhost; | |
location @fallback { | |
root /data/myapp/current/public; | |
passenger_enabled on; | |
} | |
location / { | |
set $memcached_key 'thekey'; | |
memcached_pass memcache; | |
default_type text/html; | |
error_page 404 502 = @fallback; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment