Files
proxmox-spice-client/BUILD.md
T

95 lines
2.3 KiB
Markdown
Raw 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.
# Build — Proxmox SPICE Client
## Voraussetzungen
```bash
node >= 18
npm >= 9
```
Für Linux-Builds auf Linux-Host, für Windows-Builds entweder Windows oder Wine (cross-build eingeschränkt — lieber nativ bauen).
## Entwicklung
```bash
npm install
npm start
```
## Produktions-Build
### Linux (AppImage + .deb)
```bash
npm run build:linux
# Output: dist/Proxmox SPICE Client-1.0.0.AppImage
# dist/proxmox-spice-client_1.0.0_amd64.deb
```
### Windows (.exe Installer)
```bash
npm run build:win
# Output: dist/Proxmox SPICE Client Setup 1.0.0.exe
```
### Beides auf einmal
```bash
npm run build:linux && npm run build:win
```
## Icons
Dateien in `assets/` müssen vor dem Build vorhanden sein:
| Datei | Größe | Verwendung |
|-------|-------|------------|
| `assets/icon.png` | mind. 512×512 | Linux AppImage + deb |
| `assets/icon.ico` | multi-size | Windows NSIS Installer |
| `assets/icon.icns` | multi-size | macOS (optional) |
**PNG → ICO konvertieren (Linux):**
```bash
sudo apt install imagemagick
convert assets/icon.png -resize 256x256 assets/icon.ico
```
**PNG → ICNS (macOS):**
```bash
# mit electron-icon-maker:
npx electron-icon-maker --input=assets/icon.png --output=assets/
```
## Abhängigkeit: virt-viewer
Der Client startet `remote-viewer` (Teil von virt-viewer). Muss auf dem Zielrechner installiert sein:
- **Linux:** `sudo apt install virt-viewer`
- **Windows:** https://virt-manager.org/download/ → "Windows MSI"
Die App zeigt beim ersten Verbindungsversuch einen Dialog wenn `remote-viewer` nicht gefunden wird.
## Verzeichnisstruktur
```
proxmox-spice-client/
├── src/
│ ├── main.js # Electron-Hauptprozess
│ ├── preload.js # Context-Bridge
│ ├── proxmox.js # Proxmox REST API Client
│ └── renderer/
│ ├── login.html
│ ├── login.js
│ ├── vms.html
│ ├── vms.js
│ └── styles.css
├── assets/
│ ├── icon.png # Quell-Icon (mind. 512×512)
│ ├── icon.ico # Windows
│ └── icon.icns # macOS (optional)
├── daten/ # persistente Einstellungen (Docker-Mount)
├── Dockerfile
├── docker-compose.yml
├── .env.example
├── package.json
└── BUILD.md
```