Compare commits
2 Commits
b75ec7d6e7
...
f23d782089
Author | SHA1 | Date | |
---|---|---|---|
f23d782089 | |||
4f0daabe33 |
28
nginx.conf
Normal file
28
nginx.conf
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
server {
|
||||||
|
server_name nuclear-data.only4.work;
|
||||||
|
listen 80;
|
||||||
|
listen 443 ssl http2;
|
||||||
|
root /wwwroot/nuclear-data.only4.work/html;
|
||||||
|
index index.html;
|
||||||
|
|
||||||
|
location /api/ {
|
||||||
|
proxy_pass http://127.0.0.1:35590/;
|
||||||
|
proxy_set_header Host $Host:$server_port;
|
||||||
|
proxy_set_header X-Real-IP $remote_addr;
|
||||||
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
|
proxy_set_header REMOTE-HOST $remote_addr;
|
||||||
|
add_header X-Cache $upstream_cache_status;
|
||||||
|
proxy_set_header X-Host $host:$server_port;
|
||||||
|
proxy_set_header X-Scheme $scheme;
|
||||||
|
proxy_connect_timeout 30s;
|
||||||
|
proxy_read_timeout 86400s;
|
||||||
|
proxy_send_timeout 30s;
|
||||||
|
proxy_http_version 1.1;
|
||||||
|
proxy_set_header Upgrade $http_upgrade;
|
||||||
|
proxy_set_header Connection "upgrade";
|
||||||
|
}
|
||||||
|
|
||||||
|
# 日志
|
||||||
|
access_log /wwwlogs/nuclear-data.only4.work.log;
|
||||||
|
error_log /wwwlogs/nuclear-data.only4.work.error.log;
|
||||||
|
}
|
3
pm2.sh
3
pm2.sh
@ -1,10 +1,9 @@
|
|||||||
|
# # 安装 pm2
|
||||||
# npm i -g pm2
|
# npm i -g pm2
|
||||||
# npm install pm2-windows-startup -g
|
|
||||||
|
|
||||||
# 启动服务 并设置开机启动
|
# 启动服务 并设置开机启动
|
||||||
pm2 start index.js --name nuclear-data-spider
|
pm2 start index.js --name nuclear-data-spider
|
||||||
pm2 save
|
pm2 save
|
||||||
pm2-startup install
|
|
||||||
|
|
||||||
# # 查看当前运行列表
|
# # 查看当前运行列表
|
||||||
# pm2 list
|
# pm2 list
|
||||||
|
Loading…
Reference in New Issue
Block a user