nginx configuration variable interpolation

2023-03-27 Thread Vilius Šumskas
Hello, I have the following directive in Nginx configuration: location /docs { add_header Access-Control-Allow-Origin $cors_origin; } $cors_origin comes from the map {} where the value is set to * or something else. I have noticed that if $cors_origin is set to 0, add_header doesn’t add A

Re: nginx configuration variable interpolation

2023-03-27 Thread Maxim Dounin
Hello! On Mon, Mar 27, 2023 at 03:24:06PM +, Vilius Šumskas wrote: > I have the following directive in Nginx configuration: > > location /docs { > add_header Access-Control-Allow-Origin $cors_origin; > } > > $cors_origin comes from the map {} where the value is set to * or something >

Re: How to compile Nginx with zlib-ng

2023-03-27 Thread Sergey Kandaurov
> On 24 Mar 2023, at 06:07, Maxim Dounin wrote: > > Hello! > > On Thu, Mar 23, 2023 at 09:33:19PM +0100, Richard Stanway via nginx wrote: > >> Yes, when using the latest zlib-ng on nginx-1.21.6 I received the >> alerts. Previous versions of zlib-ng have worked great after the 2021 >> patch. I

Re: How to compile Nginx with zlib-ng

2023-03-27 Thread Maxim Dounin
Hello! On Mon, Mar 27, 2023 at 09:57:34PM +0400, Sergey Kandaurov wrote: > > On 24 Mar 2023, at 06:07, Maxim Dounin wrote: > > > > Hello! > > > > On Thu, Mar 23, 2023 at 09:33:19PM +0100, Richard Stanway via nginx wrote: > > > >> Yes, when using the latest zlib-ng on nginx-1.21.6 I received t

RE: nginx configuration variable interpolation

2023-03-27 Thread Vilius Šumskas
Thank you for your response. I've made a mistake. I've made my initial tests with a lot of different combinations and last value I have used, which doesn't add header at all, is indeed an empty string, not 0. So it seems this works as expected. I think it is functionality worth documenting thoug