Forum: Cfengine Help
Subject: getindices("sys.ipv4") broken in 3.1.0
Author: Beto
Link to topic: https://cfengine.com/forum/read.php?3,19175,19175#msg-19175
The function getindices(sys.ipv4) resturns nothing and appears to be broken in
cfengine 3.1.0.
Consider the following bundle:
body common control
{
bundlesequence => {
"test"
};
}
bundle agent test
{
vars:
"intf" slist => getindices("sys.ipv4");
reports:
hpux|linux::
"[ sys.interface ] = $(sys.interface)";
"[ sys.ipv4 ] = $(sys.ipv4)";
"[ sys.ipv4[$(intf)] ] = $(sys.ipv4[$(intf)])";
"[ sys.ipv4 ] = $(sys.ipv4)";
"[ intf ] = $(intf)";
}
In 3.1.0 this bundle produces the following:
R: [ sys.interface ] = lan1
R: [ sys.ipv4 ] = 172.27.227.221
R: [ sys.ipv4 ] = 172.27.227.221
in 3.0.5p1 the following is reported:
R: [ sys.interface ] = lan1
R: [ sys.ipv4 ] = 172.27.227.221
R: [ sys.ipv4 ] = 172.27.227.221
R: [ sys.ipv4 ] = 172.27.227.221
R: [ intf ] = lan1
So there's no way in 3.1.0 to scan all the IPs used on a system.
Anyone else noticed this? Is it a bug?
_______________________________________________
Help-cfengine mailing list
[email protected]
https://cfengine.org/mailman/listinfo/help-cfengine