标签:org make down col zlib stop get 创建文件夹 Nginx部署
安装依赖包
yum install gcc
yum install pcre-devel
yum install zlib zlib-devel
yum install zlib zlib-devel
一键安装上面四个依赖
yum -y install gcc zlib zlib-devel pcre-devel openssl openssl-devel
cd /usr/local # 进入路径
mkdir nginx # 创建文件夹
cd nginx # 进入nginx文件夹
wget http://nginx.org/download/nginx-1.13.7.tar.gztar -xvf nginx-1.13.7.tar.gz # 下载tar包
cd /usr/local/nginx # 注意这个目录一定是你安装的目录
./configure # 执行命令
make
make install
进入nginx安装目录下的sbin目录
./nginx -t # 测试配置文件是否正确
./nginx # 启动(/usr/local/nginx/sbin/nginx -c /usr/local/nginx/conf/nginx.conf)
./nginx -s stop # 停止
./nginx -s reload # 动态更新文件,不关机和不关闭nginx使新的文件生效
标签:org make down col zlib stop get 创建文件夹 Nginx部署
原文地址:https://www.cnblogs.com/shizhengquan/p/10844234.html