help-cfengine
[Top][All Lists]
Advanced

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

Import not working as expected?


From: Marco Nicosia
Subject: Import not working as expected?
Date: Sat, 12 Apr 2003 23:33:12 +0000 (UTC)

Hi all,

We're attempting a first-time cfengine install in a complex environment.
I've been using the example configs from the reference guide. In that
guide, I see:

] import:
]       any::
]               cf.groups
]               cf.main
]               ...
]       hpux::  cf.hpux
]       linux:: cf.linux
]       ...

We like this style, and want to use it for ourselves, except that we
want to load action definitions based on group membership, rather than
membership defined by OS. So we wrote this cfagent.conf:

] import:
]       all::
]               cf.brsb.groups
] 
]       catw::  cf.catw
]       ...

The cf.catw file defines actions for copy and shellcommands, but we've
run into an interesting problem. Even though it imports cf.brsb.groups,
the remote system does not import cf.catw, despite knowing it is in the
correct class:

] Import file cf.brsb.groups
] ...
] Defined Classes = ( any cfengine_2_0_6 Saturday Hr12 Min19 Min15_20
] Q2 Hr12_Q2 Day12 April Yr2003 solarisx86 catw001 32_bit sunos_5_8
] i86pc sunos_i86pc sunos_i86pc_5_8 i386 sunos_i86pc_5_8_Generic_108529_14
] compiled_on_solaris2_8 catw001_f catw001_walmart_com net_iface_lo0
] net_iface_iprb0 172_28_101_130 catw001_f_walmart_com 172_28_101
] ipv4_172_28_101_130 ipv4_172_28_101 ipv4_172_28 ipv4_172 net_iface_iprb1
] 172_28_101_164 catw001_b_walmart_com catw001_b ipv4_172_28_101_164
] catw )
  ^^^^

What boggles us is that if we do not import the cf.brsb.groups, rather,
include the groups directly in cfagent.conf, it works!

] groups:
]    catw = ( catw001 catw002 catw003 catw004 catw005 catw006 catw007 )
] 
] import:
]    catw:: cf.catw

I'm thinking that import order cannot be deferred. I've read that
the actionsequence order of evaluation can be manipulated, (ie,
links.firstpass.include, links.secondpass) but I don't know how
I'd do the same for include files?

Help? Do I have to edit all groups in cfagent.conf, or is there
a way I can separate them out to a cf.groups file?

 


reply via email to

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