RHCSA SELINUX allow a apache subdirectory to be serviced

RHCSA studying. classroom.example.com 10.0.2.10 has a web server and /var/www/html/repo is where we want the yum repository to be.

A little selinux problem with that in enforcing mode.

yum -y install nmap  ##our test dummy.

The answer:

chcon -R -t httpd_sys_content_t “/var/www/html/repo/”

restorecon -R /var/www/html/repo

Like magic yum then works.

Leave a Comment

Your email address will not be published.