Details
-
Type:
Bug
-
Status: Done
-
Priority:
High
-
Resolution: Fixed
-
Affects Version/s: None
-
Component/s: Promise type: storage
-
Labels:None
Description
When passed to a nfs storage promise this works:
<pre>
bundle common nfsglobals
{
vars:
"volumes"
data => parsejson('
{
"hosts" :
{
"host" : "nfshost.example.com",
"volumes" :
[
"/PATH1",
"/PATH10",
]
}
}');
}
</pre>
While this doesn't work (PATHs interchanged):
<pre>
bundle common nfsglobals
{
vars:
"volumes"
data => parsejson('
{
"hosts" :
{
"host" : "nfshost.example.com",
"volumes" :
[
"/PATH10",
"/PATH1",
]
}
}');
}
</pre>
Likely due to substring (strstr()) comparison; https://github.com/cfengine/core/blob/master/cf-agent/nfs.c#L667