layout | title | published |
---|---|---|
default |
usemodule |
true |
[%CFEngine_function_prototype(module, args)%]
Description: Execute CFEngine module script module
with args
, and
return whether successful.
The module script is expected to be located in the registered modules
directory, WORKDIR/modules
.
[%CFEngine_function_attributes(module, args)%]
Example:
bundle agent test
{
classes:
# returns $(user)
"done" expression => usemodule("getusers","");
commands:
"/bin/echo" args => "test $(user)";
}
See also: [read_module_protocol()][read_module_protocol], [Module Protocol][commands#module]