Hello everyone,
i am trying to write my first custom fact but i don't know how. I didn't find any good instructions or list of functions i can use.
What i want to do is the following:
On our machines we have the directory "/work", There is a list of all possible subdirectories, but no machine has all of them.
Depending on the existence of the subdirectories i have to create files. Now all i need is a fact that gives me all subdirectories of "/work" but only depth=1.
e.g.
/work
|_ Sub_a
|_ Sub_b
|_ Sub_b_c
I would only need "Sub_a" and "Sub_b" returned by the fact.
Does anyone know how to do it?
Thanks Daniel