Install Apache HTTP Server on RHEL 9
Step 1 – Install
subscription-manager repos --enable codeready-builder-for-rhel-9-$(arch)-rpms
dnf install -y httpd mod_ssl
systemctl enable --now httpd
Step 2 – Open firewall ports
firewall-cmd --permanent --add-service=http
firewall-cmd --permanent --add-service=https
firewall-cmd --reload
Step 3 – Verify
curl -I http://localhost
apachectl -v
Main config: /etc/httpd/conf/httpd.conf, vhosts in /etc/httpd/conf.d/.