首页 » 编程世界 » 服务器编程 » 正文 centos7 yum安装nginx 2020/01/03 | 服务器编程 | admin | 暂无评论 | 1028 views $ vi /etc/yum.repos.d/nginx.repo [nginx] name=nginx repo baseurl=http://nginx.org/packages/centos/7/$basearch/ gpgcheck=0 enabled=1 $ yum -y install nginx 重启 systemctl restart nginx #设置开机启动 systemctl enable nginx