nginx编译相关配置

mtain 2023年02月23日 732次浏览
yum install -y gcc-c++
yum install -y pcre pcre-devel
yum install -y zlib zlib-devel
yum install -y openssl openssl-devel wget

wget -c https://nginx.org/download/nginx-1.10.1.tar.gz
tar -zxvf nginx-1.10.1.tar.gz
cd nginx-1.10.1

# 编译参数-https
./configure --prefix=/opt/nginx --with-http_ssl_module --with-stream

# 编译参数-tcp转发
./configure --prefix=/opt/nginx --with-http_stub_status_module --with-http_ssl_module --with-stream

# 编译安装
make&&make install