- NGINX Cookbook
- Tim Butler
- 77字
- 2021-07-03 00:04:29
How to do it...
Now that we have a very simple Express application, we'll place NGINX in front of it. Although Node.js is extremely fast, NGINX is not only faster but offers far more configurability. Even with WebSockets, we're still able to proxy this through NGINX. Let's take a look at the configuration:
server { listen 80; server_name express.nginxcookbook.com; access_log /var/log/nginx/express-access.log combined; location / { proxy_pass http://127.0.0.1:3000; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade"; } }
推薦閱讀
- 信息可視化的藝術(shù):信息可視化在英國(guó)
- PaaS程序設(shè)計(jì)
- C語言程序設(shè)計(jì)教程(第2版)
- 程序員考試案例梳理、真題透解與強(qiáng)化訓(xùn)練
- MATLAB定量決策五大類問題
- HTML5+CSS3網(wǎng)站設(shè)計(jì)基礎(chǔ)教程
- Visual C#通用范例開發(fā)金典
- PLC應(yīng)用技術(shù)(三菱FX2N系列)
- SQL Server實(shí)用教程(SQL Server 2008版)
- TMS320LF240x芯片原理、設(shè)計(jì)及應(yīng)用
- Visual Basic程序設(shè)計(jì)習(xí)題與上機(jī)實(shí)踐
- Arduino計(jì)算機(jī)視覺編程
- Python開發(fā)基礎(chǔ)
- OpenCV 3計(jì)算機(jī)視覺:Python語言實(shí)現(xiàn)(原書第2版)
- 玩轉(zhuǎn).NET Micro Framework移植:基于STM32F10x處理器