# Deployment Documentation ## Overview Yakety provides multiple packaging and distribution options for cross-platform deployment. The build system includes automated packaging targets for creating distributable archives, DMG installers, and deployment to remote servers. ## Package Types ### CLI Distribution Packages - **Target**: `package-cli-macos` | `package-cli-windows` - **Output**: `yakety-cli-{platform}.zip` - **Location**: `${CMAKE_BINARY_DIR}/` - **Contents**: CLI tools (yakety-cli, recorder, transcribe), models, assets ### App Distribution Packages - **Target**: `package-app-macos` | `package-app-windows` - **Output**: macOS: `Yakety-macos.dmg` + `Yakety-macos.zip` | Windows: `Yakety-windows.zip` - **Location**: `${CMAKE_BINARY_DIR}/` - **Contents**: Application bundles with embedded resources ### Universal Package Target - **Target**: `package` - **Behavior**: Platform-conditional (`package-macos` on Darwin, `package-windows` on Windows) ## Platform Deployment ### macOS ```bash # Build release binaries cmake --preset release cmake --build --preset release # Create CLI distribution cmake --build build --target package-cli-macos # Output: build/yakety-cli-macos.zip # Create app distribution with DMG cmake --build build --target package-app-macos # Output: build/Yakety-macos.dmg, build/Yakety-macos.zip # Create all packages cmake --build build --target package-macos ``` **DMG Creation Process**: 1. Copies app bundle to temp directory 2. Creates Applications symlink for drag-install 3. Generates DMG with `hdiutil create` 4. Creates compressed ZIP of DMG **Code Signing**: Automatic ad-hoc signing with `codesign --force --deep --sign -` ### Windows ```bash # Build release binaries cmake --preset release cmake --build --preset release # Create CLI distribution cmake --build build --target package-cli-windows # Output: build/yakety-cli-windows.zip # Create app distribution cmake --build build --target package-app-windows # Output: build/Yakety-windows.zip # Create all packages cmake --build build --target package-windows ``` **Windows-specific**: - CLI executable: `yakety-cli.exe` - GUI executable: `Yakety.exe` (WIN32 app without console) - Vulkan acceleration support (if VULKAN_SDK available) ### Remote Deployment ```bash # Upload packages to server cmake --build build --target upload ``` **Upload Destinations**: - **Target Server**: `badlogic@slayer.marioslab.io` - **Path**: `/home/badlogic/mariozechner.at/html/uploads/` - **Method**: Windows: SCP via batch script | Unix: rsync ### Website Deployment **Frontend-only Deploy**: ```bash cd website ./publish.sh ``` **Full Deploy with Server Restart**: ```bash cd website ./publish.sh server ``` **Docker Control**: ```bash cd website/docker ./control.sh start # Production mode ./control.sh startdev # Development mode ./control.sh stop # Stop services ./control.sh logs # View logs ./control.sh restart # Restart services ``` ## Reference ### Build Outputs - **Binary Directory**: `${CMAKE_BINARY_DIR}/bin/` - **CLI Tools**: `yakety-cli`, `recorder`, `transcribe` - **GUI Apps**: `Yakety.app` (macOS bundle) | `Yakety.exe` (Windows) - **Models**: `bin/models/ggml-base-q8_0.bin` - **Assets**: `bin/menubar.png` ### Distribution Archives - **macOS CLI**: `yakety-cli-macos.zip` - **macOS App**: `Yakety-macos.dmg`, `Yakety-macos.zip` - **Windows CLI**: `yakety-cli-windows.zip` - **Windows App**: `Yakety-windows.zip` ### Website Configuration - **Production Domain**: `yakety.ai`, `www.yakety.ai` - **SSL**: Let's Encrypt via nginx-proxy - **Server Stack**: Docker (Nginx + Node.js) - **Deployment**: rsync to `slayer.marioslab.io` ### Build Presets - **Release**: `cmake --preset release` (Ninja, optimized) - **Debug**: `cmake --preset debug` (Ninja, debugging symbols) - **VS Debug**: `cmake --preset vs-debug` (Visual Studio, Windows only) ### WSL/Remote Development - **Target**: Windows machine at `192.168.1.21` - **Sync Command**: `rsync -av --exclude='build/' --exclude='whisper.cpp/' . badlogic@192.168.1.21:/mnt/c/workspaces/yakety/` - **Build via SSH**: Uses `cmd.exe` with `winvs.bat` environment setup