安装epel源
sudo yum install epel-release
安装nginx
sudo yum install nginx
启动nginx
sudo systemctl start nginx
配置防火墙
sudo firewall-cmd --zone=public --add-service=http --permanent
sudo firewall-cmd --zone=public --add-service=https --permanent
sudo firewall-cmd --reload