1,版本
nginx-1.14
2,创建用户
groupadd www && useradd www -g www
3,安装Nginx
wget http://nginx.org/download/nginx-1.14.0.tar.gz
安装依赖
yum -y install pcre-devel openssl openssl-devel wget gcc-c++
4.解压安装
mkdir /usr/local/nginx
tar -zxvf nginx-1.14.0.tar.gz && cd nginx-1.14.0
./configure --prefix=/usr/local/nginx/ --user=www --group=www
make && make install
echo 'PATH="/usr/local/nginx/sbin:$PATH"'>> /etc/profile;source /etc/profile
转载于:https://blog.51cto.com/8047993/2114103