Lightweight CLI & GUI to connect local folders to OpenTerminal in OpenWebUI
Project description
โก OpenWebUI Bridge
Connect any local folder to OpenTerminal in one click โ no Docker knowledge required.
OpenWebUI Bridge is a lightweight Windows desktop application that eliminates the need to manually run Docker commands when switching project workspaces for OpenWebUI's OpenTerminal.
Features
- ๐ One-click workspace mounting โ browse, select, done
- ๐ฅ๏ธ Desktop GUI with live Docker + container status
- โจ๏ธ Full CLI (
owui open .,owui status, etc.) - ๐ Windows Explorer integration โ right-click any folder โ Open with OpenWebUI
- ๐ Safe โ validates paths, handles failures gracefully, never exposes API keys in logs
- ๐ Desktop notifications for every state change
- โ๏ธ Persistent configuration stored in
%APPDATA%\OpenWebUI Bridge\config.json - ๐ VS Code extension ready โ the CLI is the integration surface
Quick Start
1. Install
# Run as Administrator
installer\install.bat
2. First Launch
Launch OpenWebUI Bridge from the desktop shortcut or Start Menu.
The setup wizard will:
- Detect Docker Desktop
- Validate Docker is running
- Ask for your OpenTerminal API key, URL, and port
- Validate Docker with a test container
- Save configuration
3. Mount a Workspace
Via GUI: Click Browse, select your project folder, click ๐ Mount Workspace
Via CLI:
owui open .
owui open D:\Projects\MyApp
Via Explorer: Right-click any folder โ Open with OpenWebUI
CLI Reference
owui open [PATH] Mount a folder as /workspace
owui open . Mount current directory
owui restart Restart OpenTerminal container
owui stop Stop OpenTerminal container
owui status Show Docker + container status
owui config Show current configuration
owui config --set key=val Update a configuration value
owui logs Show last 100 container log lines
owui logs --lines 200 Show last 200 lines
owui gui Launch the desktop GUI
Configuration keys
| Key | Description | Default |
|---|---|---|
openWebUIUrl |
URL to your OpenWebUI instance | http://localhost:3000 |
apiKey |
OpenTerminal API key | (required) |
port |
Host port for OpenTerminal | 8000 |
containerName |
Docker container name | open-terminal |
currentFolder |
Last mounted folder path | (none) |
How Folder Switching Works
When you select a new folder:
- Stop the existing
open-terminalcontainer - Remove the container
- Recreate it with the same name, API key, and port โ bind-mounting your selected folder at
/home/user - Health check โ polls
http://localhost:{port}until responding - Notify โ desktop notification + status update
The Docker command used:
docker run -d \
--name open-terminal \
--restart unless-stopped \
-p 8000:8000 \
-v "D:\Projects\MyApp":/home/user \
-e OPEN_TERMINAL_API_KEY=your-secret-key \
ghcr.io/open-webui/open-terminal
The selected folder is bind-mounted directly as /home/user โ no named volume, no /workspace.
No changes are required to OpenTerminal or OpenWebUI.
Windows Explorer Integration
After installation, right-clicking any folder shows:
๐ Open with OpenWebUI
Clicking it:
- Launches the Bridge (if not running)
- Detects the selected folder
- Mounts it as
/home/user(or just opens OpenWebUI if already mounted) - Shows a desktop notification
Configuration File
Stored at %APPDATA%\OpenWebUI Bridge\config.json:
{
"openWebUIUrl": "http://localhost:3000",
"apiKey": "your-secret-key",
"containerName": "open-terminal",
"port": 8000,
"currentFolder": "D:\\Projects\\Website"
}
Security: The API key is never shown in logs or the UI (masked as
abcโขโขโขโขโข).
Building from Source
Requirements
- Python 3.10+
- Docker Desktop (for testing)
Build
# Install build dependencies
pip install pyinstaller
# Build single-directory (recommended)
python build.py
# Build single-file portable executable
python build.py --onefile
# Output: dist/owui/ or dist/owui.exe
Run without building
# GUI
python owui_bridge.py
# CLI
python owui_bridge.py status
python owui_bridge.py open D:\Projects\MyApp
VS Code Extension Integration
The CLI is designed as the single integration surface for future extensions.
A VS Code extension simply needs to:
// Mount workspace when a folder is opened
const { execSync } = require('child_process');
execSync(`owui open "${workspaceFolder.uri.fsPath}"`, { stdio: 'inherit' });
No Docker SDK, no config parsing, no container management โ the Bridge handles everything.
Project Structure
owui-bridge/
โโโ owui_bridge.py # Unified entry point (GUI + CLI)
โโโ build.py # PyInstaller build script
โโโ installer/
โ โโโ install.bat # Windows installer (run as admin)
โ โโโ uninstall.bat # Uninstaller
โโโ src/
โโโ config/
โ โโโ config_manager.py # Read/write %APPDATA% config JSON
โโโ core/
โ โโโ docker_manager.py # All Docker operations
โโโ cli/
โ โโโ cli.py # owui <command> entry point
โโโ gui/
โโโ main_window.py # Desktop GUI (tkinter)
โโโ explorer_integration.py # Windows Registry context menu
Troubleshooting
"Docker is not running" โ Start Docker Desktop and wait for it to fully initialize.
"Failed to mount workspace" โ Check that the path exists and Docker has file sharing permission for that drive (Docker Desktop โ Settings โ Resources โ File Sharing).
Context menu not appearing
โ Re-run installer\install.bat as Administrator.
Container not becoming healthy
โ Check owui logs โ the container may still be pulling the image on first use.
Wait a minute and try owui status again.
Config file location
โ %APPDATA%\OpenWebUI Bridge\config.json
Log file location
โ %APPDATA%\OpenWebUI Bridge\bridge.log
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file owui_bridge-0.1.0.tar.gz.
File metadata
- Download URL: owui_bridge-0.1.0.tar.gz
- Upload date:
- Size: 21.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ecea5ca7a1dc2722ceca3188ff3623bdd81059548aa04f58e921fc350dd3cd68
|
|
| MD5 |
7186c61bf280996caeb95e84173deaf0
|
|
| BLAKE2b-256 |
6264469c26378f8cbc4ff0b5446801e8f60e8e15a62348f1c0a3391eac81612b
|
File details
Details for the file owui_bridge-0.1.0-py3-none-any.whl.
File metadata
- Download URL: owui_bridge-0.1.0-py3-none-any.whl
- Upload date:
- Size: 21.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7b27a4b51bc7fd4985766325454fc7154046e19daf141f491a278355d5f1dd35
|
|
| MD5 |
fa463a5536958dafc05282e0dde72b3d
|
|
| BLAKE2b-256 |
7815bea369d4a46f0715e7c3026e75ab4204f22cc8b182d577e013d6cfa39272
|