Lol, thanks Jonathan.
I'll let you know what the devs will reply to this issue.

You're right, this should be done from their side as Nginx is rfc compliant ^^

But your hack can be usefull under certain circumtances :p

Regards,
Smana


----- Mail original -----
De: "Jonathan Matthews" <[email protected]>
À: [email protected]
Envoyé: Mercredi 16 Octobre 2013 15:40:42
Objet: Re: Nginx Webdav & POST method





On 16 Oct 2013 13:09, < [email protected] > wrote: 
> 
> Thanks Maxim, 
> I'll contact their support in order to understand its behavior. 

If you discover that it does indeed use POSTs in an nginx-incompatible way, you 
could use nginx to hack the request into something usable. [ NB I'd only do 
this for an absolutely immutable appliance; in any other situation I'd 
personally tell the devs their code was broken and we couldn't help: don't 
inherit other people's technical debt without a commitment to a fix! ] 

There's a directive (proxy_method?) which changes the verb when used in a 
proxy_pass'd context. 

You could just have a double pass through nginx, with the publicly-listening 
server{} solely being responsible for doing s/POST/PUT/ , before proxy_pass'ing 
to the actual webdav server via a 127.0.0.0/8 address. Use a map to define the 
verb, I suggest. 

If it's not clear from the above how to do this, let me know and I'll run up a 
test and guide you towards some config. I suggest it's not very difficult to 
do, however ;-) 

Yes, this is an utterly horrible hack. No, I have never used it in production. 
Yes, there is an lie hidden in this paragraph. 

Cheers, 
Jonathan 

_______________________________________________
nginx mailing list
[email protected]
http://mailman.nginx.org/mailman/listinfo/nginx

_______________________________________________
nginx mailing list
[email protected]
http://mailman.nginx.org/mailman/listinfo/nginx

Reply via email to