Enable puppet facts
Currently facter facts omit facts that a distributed via Puppet. This commit adds the `--puppet` option. In cases where puppet is not installed, the command sends a warning to STDERR *but* completes successfully. So should not cause any issues. The benefit is, filtering can be done based on facts set by Puppet.
This commit is contained in:
parent
7e0e6569bc
commit
8cc894bef2
1 changed files with 1 additions and 1 deletions
|
@ -91,7 +91,7 @@ def run_setup(module):
|
||||||
# if facter is installed, and we can use --json because
|
# if facter is installed, and we can use --json because
|
||||||
# ruby-json is ALSO installed, include facter data in the JSON
|
# ruby-json is ALSO installed, include facter data in the JSON
|
||||||
if facter_path is not None:
|
if facter_path is not None:
|
||||||
rc, out, err = module.run_command(facter_path + " --json")
|
rc, out, err = module.run_command(facter_path + " --puppet --json")
|
||||||
facter = True
|
facter = True
|
||||||
try:
|
try:
|
||||||
facter_ds = json.loads(out)
|
facter_ds = json.loads(out)
|
||||||
|
|
Loading…
Reference in a new issue