summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorHsieh Chin Fan <pham@topo.tw>2025-02-04 11:39:04 +0800
committerHsieh Chin Fan <pham@topo.tw>2025-02-04 11:39:04 +0800
commit88be69997cea29d9b45ae31f501d3ad1094dcec4 (patch)
treef9d92ce964fa7442a02314e71370a6a7d5b9a71f
parenteafe25e057b051c771b18e58aa3691127bd9707a (diff)
nginx
-rw-r--r--nginx/Makefile11
-rw-r--r--nginx/nginx.service21
2 files changed, 28 insertions, 4 deletions
diff --git a/nginx/Makefile b/nginx/Makefile
index cb995f7..d14e24f 100644
--- a/nginx/Makefile
+++ b/nginx/Makefile
@@ -1,21 +1,24 @@
1.ONESHELL: 1.ONESHELL:
2 2
3VERSION=1.27.2 3VERSION=1.27.3
4 4
5all: src /home/pham/git/ngx_http_proxy_connect_module 5all: src /home/pham/git/ngx_http_proxy_connect_module
6 cd $< 6 cd $<
7 patch -p1 </home/pham/git/ngx_http_proxy_connect_module/patch/proxy_connect_rewrite_102101.patch
8 ./configure
7 nginx -V |& \ 9 nginx -V |& \
8 sed -nE 's/^configure arguments: ([^\n]*)$$/\1/p' | \ 10 sed -nE 's/^configure arguments: ([^\n]*)$$/\1/p' | \
9 sed -nE 's/([^'"'"' \t\n]+('"'"'([^'"'"'\]|\\'"'"'?)*'"'"'|"([^"\\]|\\"?)*")?) ?/\1\n/gp' | \ 11 sed -nE 's/([^'"'"' \t\n]+('"'"'([^'"'"'\]|\\'"'"'?)*'"'"'|"([^"\\]|\\"?)*")?) ?/\1\n/gp' | \
10 xargs ./configure \ 12 xargs ./configure \
11 --with-http_xslt_module=dynamic \ 13 --add-module=/home/pham/git/ngx_http_proxy_connect_module
12 --with-http_dav_module \ 14 --with-http_dav_module \
13 --with-http_image_filter_module \ 15 --with-http_image_filter_module \
14 --add-dynamic-module=/home/pham/git/ngx_http_proxy_connect_module 16 # --with-http_xslt_module=dynamic \
15 make modules 17 make modules
16 make 18 make
17 sudo make install 19 sudo make install
18 #cd ../.. && rm -rf nginx 20 cd .. && rm -rf src
21 sudo ln -sf `pwd`/nginx.service /usr/lib/systemd/system/nginx.service
19 22
20src: 23src:
21 curl -O https://nginx.org/download/nginx-${VERSION}.tar.gz 24 curl -O https://nginx.org/download/nginx-${VERSION}.tar.gz
diff --git a/nginx/nginx.service b/nginx/nginx.service
new file mode 100644
index 0000000..5a4e914
--- /dev/null
+++ b/nginx/nginx.service
@@ -0,0 +1,21 @@
1[Unit]
2Description=nginx web server
3After=network-online.target remote-fs.target nss-lookup.target
4Wants=network-online.target
5
6[Service]
7Type=forking
8PIDFile=/run/nginx.pid
9PrivateDevices=yes
10PrivateTmp=true
11SyslogLevel=err
12
13ExecStart=/usr/bin/nginx
14ExecReload=/usr/bin/nginx -s reload
15Restart=on-failure
16KillMode=mixed
17KillSignal=SIGQUIT
18TimeoutStopSec=5
19
20[Install]
21WantedBy=multi-user.target