CentOS 7安装Nginx
nginx现在也算是非常常见的一个服务器了,常常被用于反向代理
References:
CentOS安装这些常见软件还是非常简单的,yum搞定一切。
- 添加epel仓库 - yum install epel-release
- 安装nginx - yum install nginx
- 启动并添加开机自启 - systemctl start nginx systemctl enable nginx
- 防火墙放端口 - firewall-cmd --permanent --zone=public --add-service=http firewall-cmd --permanent --zone=public --add-service=https firewall-cmd --reload
提醒,httpd服务(即Apache服务器)也用的80和443,所以你知道我要说啥了吧,要么换端口,要么留一个。当然,只用nginx最简单了。
 这破站
                                        这破站