增加局域网访问
This commit is contained in:
@@ -30,7 +30,12 @@ cd /opt/crypto_key
|
||||
sudo bash scripts/install-ubuntu.sh
|
||||
```
|
||||
|
||||
访问(需在本机或通过 SSH 隧道):**http://127.0.0.1:5200**
|
||||
访问:
|
||||
|
||||
- 本机:**http://127.0.0.1:5200**
|
||||
- 局域网:**http://<服务器局域网IP>:5200**(如 `http://192.168.1.100:5200`)
|
||||
|
||||
查看本机 IP:`hostname -I` 或 `ip addr`
|
||||
|
||||
```bash
|
||||
pm2 status
|
||||
@@ -48,7 +53,7 @@ pip install -r requirements.txt
|
||||
python app.py
|
||||
```
|
||||
|
||||
浏览器打开 http://127.0.0.1:5200
|
||||
浏览器打开 http://127.0.0.1:5200(局域网内其他设备用 `http://<本机IP>:5200`)
|
||||
|
||||
PM2 守护:`./pm2-start.sh`(Linux)或 `.\pm2-start.ps1`(Windows)
|
||||
|
||||
@@ -92,7 +97,7 @@ PM2 守护:`./pm2-start.sh`(Linux)或 `.\pm2-start.ps1`(Windows)
|
||||
|
||||
## 安全提示
|
||||
|
||||
- 无认证,仅绑定 `127.0.0.1`,请勿暴露公网
|
||||
- 无认证,监听 `0.0.0.0`(局域网可访问),请勿暴露到公网;建议仅在可信局域网使用
|
||||
- `data.json` 为明文密钥,已 `.gitignore`,请定期备份
|
||||
|
||||
---
|
||||
|
||||
Reference in New Issue
Block a user