help-cfengine
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Passwd file sysncs / adding/removing users.


From: Vilius Puidokas
Subject: Re: Passwd file sysncs / adding/removing users.
Date: Fri, 19 Jul 2002 02:25:08 -0400 (EDT)

i just thought maybe this would work:
editfiles:
{ /etc/passwd
ForEachLineIn "passwd.add"
        AppendIfNoSuchLine $CurrentLine
EndLoop
ForEachLineIn "passwd.remove"
...
}

not sure if anything like $CurrentLine can be achieved/is implemented.

did i make sense here? :)
v

On 19 Jul 2002, Adrian Phillips wrote:

> >>>>> "Jason" == Jason Cannon <jcannon@pocentral.com> writes:
> 
>     Jason> I would like to be able to add/delete users from passwd
>     Jason> files with cfengine but have only found a way (a very nice
>     Jason> way indeed) to replace existing users passwords.  This
>     Jason> comes in REAL handy for changing the root password on all
>     Jason> of your servers, but I would like to expand it to be able
>     Jason> to handle accounts that may come and go.
> 
>     Jason> I could write a script to do this, but it doesn't seem to
>     Jason> be the "cfengine way."
> 
>     Jason> Any ideas on adding/deleting users in the passwd file with
>     Jason> cfengine?
> 
> Well, I have been using editfiles for adding "application system"
> users. I haven't thought about scaling it to handle many users
> though because we're going to migrate to LDAP when we get time and
> then it will be unnecssary to have users in the passwd/group files,
> 
> Sincerely,
> 
> Adrian Phillips
> 
> 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]