bash -4.3 ~ # cd /usr/local/src
bash -4.3 src # wget http://nginx.org/download/nginx-1.10.1.tar.gz
bash -4.3 src # tar xf nginx-1.10.1.tar.gz
bash -4.3 src # cd nginx-1.10.1
bash -4.3 nginx-1.10.1 # useradd -M -s /sbin/nologin nginx
bash -4.3 nginx-1.10.1 # ./configure --prefix=/usr/local/nginx --user=nginx --group=nginx --with-http_ssl_module --with-http_stub_status_module
### --user、--group: 用户和组
### --with-http_ssl_module: 加载ssl
### --with-http_stub_status_module: nginx监控
bash -4.3 nginx-1.10.1 # echo $?
0
bash -4.3 nginx-1.10.1 # make
bash -4.3 nginx-1.10.1 # make install
bash -4.3 nginx-1.10.1 # echo $?
0
bash -4.3 nginx-1.10.1 # /usr/local/nginx/sbin/nginx -V #查看Nginx配置参数
nginx version: nginx /1 .10.1
built by gcc 4.4.7 20120313 (Red Hat 4.4.7-16) (GCC)
built with OpenSSL 1.0.1e-fips 11 Feb 2013
TLS SNI support enabled
configure arguments: --prefix= /usr/local/nginx --user=nginx --group=nginx --with-http_ssl_module --with-http_stub_status_module
|