OpenWarden

A tiny menu utility to manage OpenCode and OpenChamber.

Introduction

OpenWarden is a native macOS menu bar application that supervises local OpenCode and OpenChamber servers.

The application is built specifically for Apple Silicon and macOS Tahoe. It does not use Tauri, Electron, or an embedded web view.

Features

Requirements

Run For Development

Build and run the debug executable with Swift Package Manager:

make debug

Build The Application Bundle

Build the application bundle:

make release

The target:

  1. Builds an optimized ARM64 release executable.
  2. Creates a native application bundle.
  3. Copies the application metadata from Resources/Info.plist.
  4. Copies the OpenWarden application icon.
  5. Applies an ad-hoc code signature.

The resulting bundle is written to:

build/OpenWarden.app

Launch it with:

open "build/OpenWarden.app"

Build and copy the application bundle to ~/Applications with:

make install

Remove Swift Package Manager and application bundle build artifacts with:

make clean

Configuration

Open Settings from the menu bar item to configure:

An empty executable path enables automatic discovery. The resolved executable is shown as the field placeholder.

Non-sensitive settings are encoded with Codable and stored in UserDefaults. Passwords are stored as separate generic password items in macOS Keychain.

OpenCode is started as:

opencode serve --hostname <hostname> --port <port>

OpenChamber is started in foreground mode and attached to the managed OpenCode server:

OPENCODE_HOST=http://127.0.0.1:2214 \ 
OPENCODE_SKIP_START=true \ 
openchamber serve --foreground --host 127.0.0.1 --port 2212

Both services use IPv4 addresses. A wildcard bind address (0.0.0.0) is normalized to 127.0.0.1 for health checks, copied addresses, and the OpenChamber upstream connection.

When configured, the application also supplies:

OPENCODE_SERVER_USERNAME 
OPENCODE_SERVER_PASSWORD

Project Structure

Package.swift 
Makefile 
Resources/ 
  Info.plist 
  OpenWarden.svg 
  OpenWarden-1024.png 
  OpenWarden.icns 
  OpenWardenTray.svg 
  OpenWardenTray.png 
Sources/OpenWarden/ 
  AppModel.swift 
  KeychainStore.swift 
  LauncherSettings.swift 
  Localization.swift 
  MenuBarController.swift 
  OpenWardenApp.swift 
  Resources/ 
    en.lproj/Localizable.strings 
    it.lproj/Localizable.strings 
  ServiceStatus.swift 
  SettingsView.swift 
  SettingsWindowController.swift

Notes

Copyright

Copyright (C) 2026 and above Shogun (shogun@cowtech.it).

Licensed under the ISC license, which can be found at https://choosealicense.com/licenses/isc.