編譯nginx

1,nginx.org網站下載需要的源碼包

Nginx官網提供了三個類型的版本
Mainline version:Mainline 是 Nginx 目前主力在做的版本,可以說是開發版
Stable version:最新穩定版,生產環境上建議使用的版本
Legacy versions:遺留的老版本的穩定版
wget http://nginx.org/download/nginx-1.16.1.tar.gz

2,編譯

./configure --prefix=/usr/local/nginx --pid-path=/var/run/nginx.pid --group=www --user=www --with-poll_module --http-proxy-temp-path=/var/tmp/proxy_temp --http-fastcgi-temp-path=/var/tmp/fastcgi_temp --http-uwsgi-temp-path=/var/tmp/uwsgi_temp --http-scgi-temp-path=/var/tmp/cgi_temp --http-client-body-temp-path=/var/tmp/client_body_temp --http-log-path=/var/log/access.log --error-log-path=/var/log/error.log --with-pcre

make
make install

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章