how to write to a file safely in haproxy

2021-05-26 Thread reshma r
Hello all, Periodically I need to write some configuration data to a file. However I came across documentation that warned against writing to a file at runtime. Can someone give me advice on how I can achieve this safely? Appreciate any help Thank you

Re: [ANNOUNCE] haproxy-2.4.0

2021-05-26 Thread William Dauchy
On Fri, May 14, 2021 at 11:58 AM Willy Tarreau wrote: > - interoperability / protocol support: WebSocket over HTTP/2 (RFC8441) > is now supported on both sides, regardless of the version on the other > side. The cache now supports the "Vary" header with a few commonly > used headers,

Re: how to write to a file safely in haproxy

2021-05-26 Thread Илья Шипицин
Not clear what recommendation did you read. you might consider dataplane api for config management: haproxytech/dataplaneapi: HAProxy Data Plane API (github.com) On Wed, May 26, 2021, 4:32 PM reshma r wrote: > Hello all, > Periodically I need to writ

Re: how to write to a file safely in haproxy

2021-05-26 Thread Lukas Tribus
Hello, On Wed, 26 May 2021 at 13:29, reshma r wrote: > > Hello all, > Periodically I need to write some configuration data to a file. > However I came across documentation that warned against writing to a file at > runtime. > Can someone give me advice on how I can achieve this safely? You'll h

Re: how to write to a file safely in haproxy

2021-05-26 Thread reshma r
Hi, thank you for the quick response @Chipitsine This is where I read the recommendation: https://www.haproxy.com/blog/5-ways-to-extend-haproxy-with-lua/ - (search for register_init in this). @Lukas >> Are you talking about writing to the filesystem from a LUA scripts or other runtime code within

Re: how to write to a file safely in haproxy

2021-05-26 Thread reshma r
Also the configuration file I was referring to in the previous email is not the haproxy config. it is a different file that contains some json configs. Sorry for the confusion. On Wed, May 26, 2021 at 8:14 PM reshma r wrote: > Hi, thank you for the quick response > @Chipitsine This is where I re

Re: how to write to a file safely in haproxy

2021-05-26 Thread Tim Düsterhus
Reshma, On 5/26/21 4:44 PM, reshma r wrote: not). There is a requirement that the configuration file may be changed from an external portal. So whenever a change is made in the portal I would like to update my configuration file accordingly. To do this, I am making a socket call which periodical

[PATCH] MINOR: cfgparse: Fail when encountering extra arguments in macro

2021-05-26 Thread Tim Duesterhus
This resolves GitHub issue #1124. This change should be backported as a *warning* to 2.4. --- src/cfgparse.c | 59 -- 1 file changed, 57 insertions(+), 2 deletions(-) diff --git a/src/cfgparse.c b/src/cfgparse.c index 8132e47e8..adc903b53 100644 --

Re: how to write to a file safely in haproxy

2021-05-26 Thread reshma r
Hi Tim thanks a lot for the reply. I am not familiar with what a sidecar process is. I will look into it. If it is specific to haproxy, if you could point to some relevant documentation that would be helpful. >I am making a > socket call which periodically checks whether the portal has been change

Re: [EXTERNAL] Re: Connections initiated from back end timeout if routed to same back end

2021-05-26 Thread Peter Scott (US 172D)
Thanks.  Inline: On 5/19/2021 8:23 PM, Willy Tarreau wrote: Hello, On Wed, May 19, 2021 at 01:52:10PM -0700, Peter Scott (US 172D) wrote: We have observed some behavior we do not understand with haproxy-1.5.18-6.e17.x86_64 and need help determining what is going on and how to get the desired b

Re: [EXTERNAL] Re: Connections initiated from back end timeout if routed to same back end

2021-05-26 Thread Willy Tarreau
On Wed, May 26, 2021 at 03:46:36PM -0700, Peter Scott (US 172D) wrote: > > > frontend internal_http_80 > > >    bind xxx.xxx.xxx.xxx:80 transparent > > >    default_backend internal_http_80_backend > > > > > > backend internal_http_80_backend > > >    balance leastconn > > >    source 0.0.0.0

Re: [PATCH] MINOR: cfgparse: Fail when encountering extra arguments in macro

2021-05-26 Thread Willy Tarreau
On Wed, May 26, 2021 at 05:45:33PM +0200, Tim Duesterhus wrote: > This resolves GitHub issue #1124. > > This change should be backported as a *warning* to 2.4. Merged, thank you Tim! Willy

Re: how to write to a file safely in haproxy

2021-05-26 Thread Willy Tarreau
Hi, On Wed, May 26, 2021 at 10:43:17PM +0530, reshma r wrote: > Hi Tim thanks a lot for the reply. I am not familiar with what a sidecar > process is. I will look into it. If it is specific to haproxy, if you could > point to some relevant documentation that would be helpful. It's not specific to

Re: [ANNOUNCE] haproxy-2.4.0

2021-05-26 Thread Willy Tarreau
On Wed, May 26, 2021 at 02:40:22PM +0200, William Dauchy wrote: > Regarding prometheus, it should probably noted some major changes > regarding some metrics, such as for health check, where the value is > now located in a label, instead of the value of the metric itself: > see also > http://git.ha

Re: Software Design for source code?

2021-05-26 Thread Willy Tarreau
Hi, On Fri, May 21, 2021 at 12:30:26PM +0200, Robert Ionescu wrote: > Hi, > > Are there any sources which are overviewing the HAProxy software design in > images or similar? > I would like to get a better understanding of the HAProxy components. There are *some* docs in doc/internals/, in variou

Re: [PR] DOC: Fix typo in starter guide

2021-05-26 Thread Willy Tarreau
On Sat, May 22, 2021 at 08:23:02PM +0200, PR Bot wrote: > Dear list! > > Author: Mark Mullan > Number of patches: 1 > > This is an automated relay of the Github pull request: >DOC: Fix typo in starter guide > > Patch title(s): >DOC: Fix typo in starter guide (...) Applied, thanks. Wi