Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

selinux_current_mode core fact no longer exists #74

Closed
midnightblackwolf opened this issue Dec 9, 2015 · 4 comments
Closed

selinux_current_mode core fact no longer exists #74

midnightblackwolf opened this issue Dec 9, 2015 · 4 comments

Comments

@midnightblackwolf
Copy link

In config.pp you are checking for the value of the fact selinux_current_mode to see if a 'notice' that a reboot is required to fully disable selinux is logged. As of facter 2.2, that core fact no longer exists.
We're running 2015.2 and the equivalent fact in facter 3.1 is os.selinux.current_mode.

@midnightblackwolf
Copy link
Author

The only notice that we see is:
selinux
which happens over and over, on every run.

@vinzent
Copy link
Contributor

vinzent commented Dec 23, 2016

can't reproduce:

#> /opt/puppetlabs/bin/facter selinux_current_mode
enforcing
#> /opt/puppetlabs/bin/puppet --version
4.8.1
#> /opt/puppetlabs/bin/facter --version
3.5.0 (commit 872c5707799c1c30925b632f20eab763ec03b5a4)

IMHO as long as Puppet 3.8.7 is supported the old name should be used.

@alexjfisher
Copy link
Member

I think the fact does exist, but is only when selinux is enabled.
In facter 2, the code is quite easy to read. There is a confine :selinux => true
In facter 3, selinux_current_mode is also a legacy fact, so won't appear in the command line output when you just run facter by itself.

This legacy fact is hidden by default in Facter’s command-line output.

But it definitely still exists.
Again, it is only set if selinux is enabled.

@alexjfisher
Copy link
Member

This issue is also 12 months old, so I'm going to close.
@midnightblackwolf Please feel free to open a new issue or reopen this one if you're still having problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants