KtvSetup/README.md
2025-06-13 09:27:29 +08:00

54 lines
1.3 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# KTV Heartbeat + FTP 自動安裝工具
這個工具包會在機器上自動部署:
1. 開機自動上報心跳至後台 API
2. 安裝並設定 IIS FTP Server
---
## ⚙️ 安裝步驟:
1. 準備:
-`KtvSetup` 整包複製到每台設備上
2. 安裝:
- 右鍵以「系統管理員身份」執行 `install.ps1`
---
## 📁 結構說明
```
KtvSetup/
├── install.ps1
├── scripts/
│ ├── heartbeat.ps1
│ ├── config.json
│ └── setup-ftp.ps1
```
## 🧾 安裝內容:
- 自動部署下列腳本至 `C:\scripts\`
- `heartbeat.ps1`:每分鐘上傳設備狀態
- `config.json`設備設定值API 路徑、FTP 帳密等)
- `setup-ftp.ps1`FTP 伺服器自動安裝與設定
- 建立工作排程於開機時執行 `heartbeat.ps1`
- 自動安裝:
- IIS Web Server
- FTP Server 與 FTP Extensibility
- IIS 管理主控台
- 建立指定的 FTP 使用者
- 配置 FTP Site使用電腦名稱
- 設定防火牆開放 FTP Port
---
## 📌 注意事項:
- 安裝後會在每次開機時,自動執行心跳腳本。
- 若要修改設定,只需編輯 `C:\scripts\config.json`
- 若需卸載,請移除排程工作:
```powershell
Unregister-ScheduledTask -TaskName "KtvHeartbeat" -Confirm:$false