-
安装gcc
yum install gcc-c++
-
安装 PCRE pcre-devel
yum install -y pcre pcre-devel
-
安装zlib
yum install -y zlib zlib-devel
-
安装OpenSSL
yum install -y openssl openssl-devel
-
下载nginx安装包,地址: https://nginx.org/en/download.html
-
解压nginx压缩包
tar -zxvf nginx-1.21.3.tar.gz
-
安装nginx
cd nginx-1.21.3 ./configure make make install
-
启动nginx
sh /usr/local/nginx/sbin/nginx
配置文件路径: /usr/local/nginx/conf/nginx.conf
CentOS7安装Nginx
young
481
2021-10-17