概述
以前觉得在CentOS上面安装配置 Nginx肯定麻烦,所以一直没有动。今天试了一下发现还挺简单的,只需要几步就OK。
安装 Nginx
配置 yum 源:
[Nginx] name=Nginx repo baseurl=http://Nginx.org/packages/mainline/centos/7/$basearch/ gpgcheck=0 enabled=1
systemctl start Nginx.service //启动apache systemctl stop Nginx.service //停止apache systemctl restart Nginx.service //重启apache systemctl enable Nginx.service //设置apache开机启动