| Facter 3 creates core legacy facts where part of the name can include network interface names, block devices, etc so those need to be filtered out as well. For posterity, the query I came up with is:
{ |
"query": |
["and", |
["~", "name", ".*\\..*"], |
["not", |
["or", |
["~", "name", "^blockdevice_.+_(model|size|vendor)"], |
["~", "name", "^(ipaddress|macaddress|mtu|netmask|network)_"], |
["~", "name", "^(ipaddress|macaddress|netmask|network|scope)6_"], |
["~", "name", "^sp_"], |
["~", "name", "^zone_.+_(brand|iptype|name|uuid|id|path|status)"] |
] |
] |
] |
}
|
The one liner version of that is:
$ curl -s -X POST http://localhost:8080/pdb/query/v4/fact-names -H 'Content-Type:application/json' -d '{"query":["and",["~","name",".*\\..*"],["not",["or",["~","name","^blockdevice_.+_(model|size|vendor)"],["~","name","^(ipaddress|macaddress|mtu|netmask|network)_"],["~","name","^(ipaddress|macaddress|netmask|network|scope)6_"],["~","name","^sp_"],["~","name","^zone_.+_(brand|iptype|name|uuid|id|path|status)"]]]]}'
|
|