9.10.4. Configuring SELinux


Node hosts require a specific SELinux policy and context configuration to operate correctly. Run the following commands to set the required Boolean values:
# setsebool -P httpd_unified=on httpd_can_network_connect=on httpd_can_network_relay=on httpd_read_user_content=on httpd_enable_homedirs=on httpd_run_stickshift=on allow_polyinstantiation=on
Table 9.6. Boolean Value Options
Boolean Value Purpose
httpd_unified Allow the node host to write files in the http file context.
httpd_can_network_connect Allow the node host to access the network.
httpd_can_network_relay Allow the node host to access the network.
httpd_read_user_content Allow the node host to read application data.
httpd_enable_homedirs Allow the node host to read application data.
httpd_run_stickshift Allow the node host to read application data.
allow_polyinstantiation Allow polyinstantiation for gear containment.
Relabel a number of files with the correct SELinux contexts. Specify these contexts with:
# restorecon -rv /var/run
# restorecon -rv /var/lib/openshift /etc/openshift/node.conf /etc/httpd/conf.d/openshift

Note

If you use the kickstart or bash script, the configure_selinux_policy_on_node function performs these steps.
Red Hat logoGithubRedditYoutubeTwitter

Learn

Try, buy, & sell

Communities

About Red Hat Documentation

We help Red Hat users innovate and achieve their goals with our products and services with content they can trust.

Making open source more inclusive

Red Hat is committed to replacing problematic language in our code, documentation, and web properties. For more details, see the Red Hat Blog.

About Red Hat

We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.

© 2024 Red Hat, Inc.