.ONESHELL: VERSION=1.27.2 all: src /home/pham/git/ngx_http_proxy_connect_module cd $< nginx -V |& \ sed -nE 's/^configure arguments: ([^\n]*)$$/\1/p' | \ sed -nE 's/([^'"'"' \t\n]+('"'"'([^'"'"'\]|\\'"'"'?)*'"'"'|"([^"\\]|\\"?)*")?) ?/\1\n/gp' | \ xargs ./configure \ --with-http_xslt_module=dynamic \ --with-http_dav_module \ --with-http_image_filter_module \ --add-dynamic-module=/home/pham/git/ngx_http_proxy_connect_module make modules make sudo make install #cd ../.. && rm -rf nginx src: curl -O https://nginx.org/download/nginx-${VERSION}.tar.gz tar zxvf nginx-${VERSION}.tar.gz && mv nginx-${VERSION} $@ config: ln -sf `pwd`/* /etc/nginx /home/pham/git/ngx_http_proxy_connect_module: git clone https://github.com/chobits/ngx_http_proxy_connect_module $@