Custom Fact displayed incomplite

Problem:
I created a custom fact to list all members of local groups. The output for this fact looks like this {"groups":{"adm":"syslog,u011007,a2011007","audio":"pulse","cdrom":"u011007,a2011007","dialout":"u011007,a2011007","dip":"u011007,a2011007","disk":"u011007,a2011007","docker":"u011007","ipsecd":"u011007,a2011007","lpadmin":"u011007,a2011007","plugdev":"u011007,a2011007","sambashare":"u011007,a2011007","scanner":"saned","sudo":"u011007","users":"u011007,a2011007","vboxusers":"u011007,a2011007","video":"u011007,a2011007","wireshark":"u011007,a2011007"}}. But if I display the facts in foreman i can see all but the docker group.

I assume that during testing invalid date was written to the facts database. I already run foreman-rake facts:clean but it didn’t fix the problem.

Expected outcome:
All groups are displayed as discovered by the custom fact

Foreman and Proxy versions:
Foreman 3.13.0 and 2.4.0

Distribution and version:
Red Hat Enterprise Linux release 9.5 and CentOS Linux release 7.9.2009

I know subscription-manager facts have a 255-character limit for values. Not sure about other types of facts. But maybe it would help to split the top level fact into several facts.

I did some more testing. First I change the name of the top level fact but it did not help. This indicates to me its not a problem related to old maybe incorrect formatted data. Also limiting the amount of groups listed didn’t help. What helped is to translate the docker group name into something else. Its almost like there is a filter excluding facts named docker.

There is indeed, and it’s hard-coded here:

However, I believe you can override the default by changing the Setting “excluded_facts”.

1 Like