Proxy for database updates
    Chris Savery 
    chrissavery at gmail.com
       
    Sun Sep  7 08:20:25 MSD 2008
    
    
  
Hello,
I have two servers and want to confine database updates to one of them. 
My code is clean in the sense all updates happen through POST requests 
only. Is this the way to proxy or relay on the POST updates to the 
server that handles data writes?
    server {
       ...
     if($request_method = 'POST)
          proxy_pass http://my.updateserver.com;
    ... code for normal local get requests
}
Or do I have to put more in there so the proxy requests don't fall 
through and do local stuff too? Like "last" for rewrite or something?
Thanks,
Chris :)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://nginx.org/pipermail/nginx/attachments/20080907/5601a56c/attachment.html>
    
    
More information about the nginx
mailing list