Re: Question about IF and auth subrequest

2021-02-25 Thread Vincent Blondel
Thank You for the update, Will try and let You know ... -V. On Wed, Feb 24, 2021 at 9:03 PM Maxim Dounin wrote: > Hello! > > On Wed, Feb 24, 2021 at 06:44:49PM +0100, Vincent Blondel wrote: > > > Thank You for the swift answer Maxim. > > If I understand, you mean something like that should be go

Re: Question about IF and auth subrequest

2021-02-24 Thread Maxim Dounin
Hello! On Wed, Feb 24, 2021 at 06:44:49PM +0100, Vincent Blondel wrote: > Thank You for the swift answer Maxim. > If I understand, you mean something like that should be going to Work ... > > location /subrequest/ { > proxy_pass xxx; > } > location /anyrequest/ { > auth_request /subrequest/; > e

Re: Question about IF and auth subrequest

2021-02-24 Thread Vincent Blondel
Thank You for the swift answer Maxim. If I understand, you mean something like that should be going to Work ... location /subrequest/ { proxy_pass xxx; } location /anyrequest/ { auth_request /subrequest/; error_page 400 = @fallback; proxy_pass xxx; } location @fallback { proxy_pass_request_body of

Re: Question about IF and auth subrequest

2021-02-24 Thread Maxim Dounin
Hello! On Wed, Feb 24, 2021 at 10:39:57AM +0100, Vincent Blondel wrote: > Hello all, > I have a quick question about the usage of IF and auth_request. > I would like to know if it is possible to use a IF statement to condition > the proxy behaviour of one /location depending on the response heade

Question about IF and auth subrequest

2021-02-24 Thread Vincent Blondel
Hello all, I have a quick question about the usage of IF and auth_request. I would like to know if it is possible to use a IF statement to condition the proxy behaviour of one /location depending on the response headers of the sub auth request ... location /subrequest/ { proxy_pass xxx; } loca