Install Nginx on AlmaLinux 9
Step 1 – Update and enable EPEL
dnf update -y
dnf install epel-release -y
Step 2 – Install Nginx
dnf install -y nginx
Step 3 – Enable and start
systemctl enable --now nginx
Step 4 – Firewall
firewall-cmd --permanent --add-service=http
firewall-cmd --permanent --add-service=https
firewall-cmd --reload
Step 5 – Verify
nginx -v
curl -I http://localhost
Config: /etc/nginx/nginx.conf, vhosts in /etc/nginx/conf.d/.