顯示頁面舊版反向連結Fold/unfold all回到頁頂 本頁是唯讀的,您可以看到原始碼,但不能更動它。您如果覺得它不應被鎖上,請詢問管理員。 ====== Alpine 安裝 Nginx 當 Web Proxy ====== <note tip> \\ **建議改用 [[tech/nginx_proxy_manager|Nginx Proxy Manager]] 來替代** \\ \\ </note> * 安裝環境 : * 使用 PVE 7 的 CT Template - alpine-3.15-default_20211202_amd64.tar.xz ===== 安裝程序 ===== * 先更新預設套件 <cli> apk update apk upgrade </cli> * 安裝與設定 nginx <cli> apk add nginx adduser -g 'Nginx www user' -h /var/www/html webuser vi /etc/nginx/nginx.conf </cli><file> : http { : client_max_body_size 0m; : #tcp_nopush on; : gzip on; : } </file> * 安裝 Let's Encrypt bot <cli> apk add certbot certbot-nginx apk add python3 python3-dev py3-pip build-base libressl-dev musl-dev libffi-dev rust cargo </cli> * 將 Web Proxy 設定檔放入 /etc/nginx/http.d/ 內 * 設定啟動 nginx <cli> rc-service nginx start rc-update add nginx </cli> ===== 參考網址 ===== * https://www.cyberciti.biz/faq/how-to-install-nginx-web-server-on-alpine-linux/ * https://www.ichiayi.com/tech/nginx_proxy_real_ip * https://geko.cloud/en/nginx-letsencrypt-certbot-docker-alpine/ {{tag>alpine nginx revers-proxy}} tech/alpine_nginx.txt 上一次變更: 2023/06/28 13:56由 jonathan