Help with managing regions in a config file.

2012-01-26 Thread Nick Anderson
I am trying to manage the "Match User" and "Match Group" sections in sshd_config. I am not sure what I don't have quite right. It works if I have only one section, but when I try to manage multiple sections it doesnt work. I get warnings on the first pass with the delete sections, because they

Re: CFEngine Help: Re: CFEngine Help: Re: maintaining /etc/security/limits.conf with cf3

2012-01-26 Thread Nick Anderson
On 01/24/2012 05:20 PM, no-re...@cfengine.com wrote: > Forum: CFEngine Help > Subject: Re: CFEngine Help: Re: maintaining /etc/security/limits.conf with cf3 > Author: milindk > Link to topic: https://cfengine.com/forum/read.php?3,24612,24641#msg-24641 > > Does this work ? Thanks it works, but com

CFEngine Help: Re: CFEngine Help: Re: maintaining /etc/security/limits.conf with cf3

2012-01-26 Thread no-reply
Forum: CFEngine Help Subject: Re: CFEngine Help: Re: maintaining /etc/security/limits.conf with cf3 Author: milindk Link to topic: https://cfengine.com/forum/read.php?3,24612,24667#msg-24667 Thanks , I may need to make change on my side too :) then ___

Re: CFEngine Help: Re: CFEngine Help: Re: maintaining /etc/security/limits.conf with cf3

2012-01-26 Thread Nick Anderson
I also added an insert_lines for "# End of file" because if you don't have it, it errors. Though I think it's not necissary to have that before "# End of file" location directive. Did you have a specific reason why you added it? no-re...@cfengine.com wrote: >Forum: CFEngine Help >Subject: Re

CFEngine Help: Re: Help with managing regions in a config file.

2012-01-26 Thread no-reply
Forum: CFEngine Help Subject: Re: Help with managing regions in a config file. Author: zzamboni Link to topic: https://cfengine.com/forum/read.php?3,24665,24669#msg-24669 Hi Nick, The problem seems to be in the definition of the regions. The regular expressions in select_start and select_end are

Re: CFEngine Help: Re: Help with managing regions in a config file.

2012-01-26 Thread Nick Anderson
Thanks Diego, I had a feeling it was in the select_region body but had not pinned it down. I'll take a closer look this evening to make sure I better understand. no-re...@cfengine.com wrote: >Forum: CFEngine Help >Subject: Re: Help with managing regions in a config file. >Author: zzamboni >Li

CFEngine Help: Re: CFEngine Help: Re: maintaining /etc/security/limits.conf with cf3

2012-01-26 Thread no-reply
Forum: CFEngine Help Subject: Re: CFEngine Help: Re: maintaining /etc/security/limits.conf with cf3 Author: milindk Link to topic: https://cfengine.com/forum/read.php?3,24612,24671#msg-24671 Oh no , in my build the limits.conf has last line as # End of File I just wanted to have all my config be

Re: CFEngine Help: Re: CFEngine Help: Re: maintaining /etc/security/limits.conf with cf3

2012-01-26 Thread Nick Anderson
yeah you had the before section, but I didn't see anything that ensured the "# End of File" string was actually in the file, maybe I just missed it. For what it's worth I found that negative look ahead pattern in replace_or_add in the stdlib. no-re...@cfengine.com wrote: >Forum: CFEngine Hel

Re: CFEngine Help: Re: Help with managing regions in a config file.

2012-01-26 Thread Nick Anderson
Ah yes, I see now what I did wrong. Thanks again Diego! Nick Anderson wrote: >Thanks Diego, I had a feeling it was in the select_region body but had >not pinned it down. I'll take a closer look this evening to make sure >I better understand. > >no-re...@cfengine.com wrote: > >>Forum: CFEngin