Linux 非root用户安装nginx

Linux 非root用户安装nginx

wget http://nginx.org/download/nginx-1.9.3.tar.gz

tar -zxvf nginx-1.9.3.tar.gz

cd nginx-1.9.3

./configure --prefix=/你的目录/nginx \

--sbin-path=/你的目录//nginx/nginx \

--conf-path=/你的目录//nginx/nginx.conf \

--pid-path=/你的目录//nginx/nginx.pid \

--with-http_ssl_module 

使用linux root用户授权

进入 你的目录/ 

chown root nginx

chmod u+s nginx

chown root nginx.pid

chmod u+s nginx.pid

参考:http://blog.itpub.net/29773961/viewspace-1377290/

猜你喜欢

转载自crabdave.iteye.com/blog/2360462