On Thu, Jan 28, 2010 at 09:22:49AM -0500, B. Alexander wrote: >Therein lies the problem. If you look at all of the users on a system, there >are several that aren't under /home. Just looking on my workstation, the >following home directories are on the system: > >$ cat /etc/passwd | grep false | awk -F: '{ print $6 }' >/var/spool/exim4 >/var/lib/nfs <snip> > >I would like to perform operations on *all* of the home directories. >Especially since I am updating our cfengine compliance file for NIST SP800-53 >at work... > >I'll have a look at mountpattern in the manual
Might this be better incorporated into a module instead? The various mountpattern/homepattern options in cf2 are a tad strange, and seem geared mostly towards NFS. They also do not appear to use the home directories stored in /etc/passwd (or equivilent database), but instead just follow the $(mountpattern)/$(homepattern) motif. > >Thanks, >--b > >On Wed, Jan 27, 2010 at 2:30 PM, michoski ><micho...@cisco.com<mailto:micho...@cisco.com>> wrote: >On 1/27/10 7:04 AM, "B. Alexander" ><stor...@gmail.com<mailto:stor...@gmail.com>> wrote: >> Here is the output of editfiles: >> >> ********************************************************************* >> Main Tree Sched: editfiles pass 1 @ Wed Jan 27 09:31:23 2010 >> ********************************************************************* >> >> Begin editing /etc/skel/.bashrc >> End editing /etc/skel/.bashrc >> ..................................................................... >> cfengine:worf: Program does not define mountpattern >> cfengine:worf: Mountpattern is undefined >> Begin editing /etc/ssh/ssh_config >> ..................................................................... >> Begin editing /var/spool/cron/crontabs/root >> End editing /var/spool/cron/crontabs/root >> ..................................................................... > >From the message, I suspected the "home" shortcut you alluded to from the >reference manual (I saw it to, and was never brave enough to try it) had >some other dependency... As is often the case with free community >documentation, written by experts which long-ago forgot what it was like not >to actually understand what it is they're talking about. ;) > >Really though... It seems "home" can't expand to anything unless you've >defined mountpattern (it doesn't just magically map to a users home). I'm >not sure you'd typically want/need to do that, unless you have cfengine >managing mounts already. > >""" >4.10.50 mountpattern > >mountpattern = ( mount-point ) > >The mountpattern list is used by the cfengine model for mounting nfs >filesystems. See ???undefined??? [NFS resources], page ???undefined???. It is >also >used in the evaluation of the pseudo variable home, See Section 4.19 >[files], page 94, Section 4.39 [tidy], page 146. >""" > >It may be easier just to specify a path if all your home directories are in >the same place, or define your own variable and set it based upon something >like architecture. > > Content-Description: ATT00001..txt >_______________________________________________ >Help-cfengine mailing list >Help-cfengine@cfengine.org >https://cfengine.org/mailman/listinfo/help-cfengine -- Jesse Becker NHGRI Linux support (Digicon Contractor) _______________________________________________ Help-cfengine mailing list Help-cfengine@cfengine.org https://cfengine.org/mailman/listinfo/help-cfengine