Reach your Codex workspace
Connect through Web User while Web Admin handles local gateway management, pairing, and configuration.
A self-hosted tool by KomodoDev
Bring Codex, your devices, and everyday tools together through a gateway you run on your own machine.
macOS and Ubuntu · Web Admin and Web User · Local configuration
$ uv run codexgate setup# Run it as a user service$ uv run codexgate service start# Connect a device$ uv run codexgate pair --qrCommand directory
Choose a command below, then jump to its explanation and examples. Commands run from your gateway installation.
setup [component]Prepare dependencies and configuration
migrateApply database migrations
service installRegister the user service
service startStart gateway processes
service stopStop gateway processes
service restartRestart gateway processes
service statusInspect gateway status
service restart-apiRestart only the API
service restart-runtimeRestart only Runtime Codex
service restart-whatsappRestart Runtime WhatsApp
service restart-automationRestart Runtime Automation
service restart-toolsRestart Runtime Tools
service restart-third-partyRestart Runtime Third Party
service uninstallRemove service registration
admin serveRun Web Admin in foreground
admin service installRegister the Admin service
admin service startStart Web Admin
admin service stopStop Web Admin
admin service restartRestart only Web Admin
admin service statusInspect Admin status
admin service uninstallRemove Admin registration
pairCreate a pairing code or QR
pairingsList pairing history
devices listList registered devices
devices grantChange management permission
verifyApprove one pending pairing
approveAlias of verify
rejectReject one pairing
suspendSuspend a device
revokeRevoke device access
reactivateCreate a fresh pairing invitation
app-serversDiscover local Codex App Servers
s3 key-initInitialize the local master key
s3 profilesList storage profile metadata
s3 putCreate a storage profile
s3 deleteDelete a stored profile
plugins settings listList provider configuration metadata
plugins settings showRead masked configuration
plugins settings setPatch configuration from a private file
plugins settings import-envImport legacy provider settings
web setupInstall locked web dependencies
web buildBuild the user or Admin web app
superviseRun the gateway supervisor
serveRun API workers
runtimeRun Runtime Codex
whatsapp-runtimeRun Runtime WhatsApp
automation-runtimeRun Runtime Automation
third-party-runtimeRun Runtime Third Party
tools-runtimeRun Runtime Tools
No commands match your search. Try “pair”, “setup”, or “service”.
Use codexgate --help after binary installation, or append --help to a command for its exact options. approve is an alias of verify.
One place to connect
Connect through Web User while Web Admin handles local gateway management, pairing, and configuration.
Use configured plugin profiles, Cloudflare tunnels, WhatsApp, storage, and automation from a shared gateway.
Run gateway processes under your OS user. Manage devices, credentials, services, and migrations explicitly.
Installation
Run in Terminal as your normal OS user. The installer detects your operating system and processor, downloads the latest release, and installs or updates CodexGate. Existing settings and data are preserved.
Supports macOS and Ubuntu on Intel/AMD 64-bit and ARM64. curl must already be available. On Ubuntu, the installer prepares missing system dependencies and asks for your sudo password when needed.
curl -fsSL https://github.com/komododevapp/codexgate/releases/latest/download/install.sh | shThe same command handles future updates, including migrations and managed service restarts. Initial application configuration is described in the setup reference.
Use service status to see the current state and service addresses.
codexgate service status
codexgate admin service statusCLI reference
Examples below use codexgate from the source checkout. The command name is codexgate; uv run selects its project environment. Commands that print structured output support --json where noted.
setup [component]Prepare an installation or a selected dependency. Omitting the component selects all. Existing configuration is reused; setup is not a gateway service restart.
| Component | Purpose |
|---|---|
all | Prepare Codex, PostgreSQL and migrations, Centrifugo, Evolution, Garage, and plugins. |
codex | Check or install the supported local Codex CLI. Login remains a separate operator action. |
postgres | Prepare the local PostgreSQL login/database and apply migrations. |
centrifugo | Prepare realtime configuration; a shared service may require a separate reload. |
evolution | Connect or prepare the native Evolution API used for WhatsApp. |
garage | Prepare local S3-compatible storage and its connection profile. |
blender · remotion | Prepare the selected local application's requirements. |
plugins | Install gateway plugin packages; repeat --plugin to select plugins. |
instructions | Prepare gateway-managed workspace instructions. |
nginx | Generate a proxy template, or explicitly prepare an inactive site configuration. |
check | Inspect setup status without installing components. |
codexgate setup check
codexgate setup postgres
codexgate setup plugins --plugin codexgate-tool
codexgate setup centrifugo --centrifugo-config /path/to/config.toml
codexgate setup nginx --domain gateway.example.com--yes uses existing settings/defaults without the wizard; review configuration first. Nginx options include --target gateway|storage|garage, --mode template|install, --output, upstreams, listen port, and TLS certificate/key paths. Use setup --help before preparing a site; generation is not proxy activation.
migrateApply pending Alembic migrations to the configured database. Setup runs this as part of PostgreSQL preparation; updates should run it explicitly after stopping gateway services.
codexgate migrateA database connection and the migration files from the installed version must be available. If migration fails, resolve the reported error before starting that version.
service <action>Manage the gateway's native user service. macOS uses launchd; Ubuntu uses the user's systemd service. Registration and startup are separate actions.
| Action | Behavior |
|---|---|
install | Register without starting. Optional --project-dir selects the installation directory. |
start · stop · restart | Start, stop, or restart the gateway supervisor and its owned processes. |
status | Show service status. Add --json for machine-readable output. |
restart-api | Restart only the API workers. |
restart-runtime | Restart only Runtime Codex. |
restart-whatsapp | Restart only Runtime WhatsApp. |
restart-automation | Restart only Runtime Automation. |
restart-tools | Restart only Runtime Tools. |
restart-third-party | Restart only Runtime Third Party. |
uninstall | Remove the native gateway service registration; not a database deletion. |
codexgate service status --json
codexgate service restart-apiAll listed service actions accept --json. restart-runtime controls the gateway runtime, not the separate Codex App Server daemon. Web Admin has its own service below.
adminadmin serve runs Web Admin in the foreground. admin service manages its independent native user service.
codexgate admin service install
codexgate admin service start
codexgate admin service status --json
codexgate admin service restartAvailable service actions: install, start, stop, restart, status, and uninstall. Each accepts --json; install also accepts --project-dir. Restarting Admin does not restart the gateway API or its runtimes.
webweb setup installs exact frontend dependencies with npm. web build builds the selected React application without restarting services.
codexgate web setup
codexgate web build --target user
codexgate web build --target admin --install--target accepts user or admin and defaults to user. --install forces dependency installation before build. Source builds need Node.js 22.12+ and npm.
pairCreate a short-lived pairing invitation. Use --qr to display a QR in the terminal, or --json for structured output; the two flags are mutually exclusive.
codexgate pair --qrpairingsList pairing history and IDs. Filter with --status all|pending|approved|revoked; default is all. Optional --json returns structured output.
codexgate pairings --status pendingdevicesdevices and devices list show registered devices. Grant or remove gateway-management permission without re-pairing using an exact device UUID.
codexgate devices list
codexgate devices grant <device_id> --manage-gateway true
codexgate devices grant <device_id> --manage-gateway falseDevice listing and grant accept --json. Grant explicitly requires --manage-gateway true|false.
verify <pairing_id> alias: approveApprove one exact pending pairing. Add --manage-gateway only when management access is intended. Optional --json returns the result.
codexgate verify <pairing_id>
codexgate approve <pairing_id> --manage-gatewayreject <pairing_id>Reject one pending pairing request. Accepts --json.
suspend <device_id>Suspend an existing device's gateway access. Accepts --json.
revoke <device_id>Revoke the selected device's gateway access. Confirm the exact device before executing. Accepts --json.
reactivate <device_id>Create a new pairing invitation for an existing device. This is not immediate approval. Accepts --json.
app-serversDiscover local Codex App Servers without stopping or restarting them. Add --json for structured discovery, --pid for one process, or --use-socket to save a discovered local Unix endpoint into .env.
codexgate app-servers --json
codexgate app-servers --use-socketAdvanced option --show-token requires --pid and can reveal a private token. Do not use it for ordinary discovery or share its output.
s3Manage encrypted S3 connection profiles. Private JSON files are read locally; do not put credentials in shell arguments or public documentation.
| Command | Purpose |
|---|---|
s3 key-init | Initialize the local master key without printing or replacing an existing key. |
s3 profiles | List profile metadata without credentials. |
s3 put <name> --file <path> | Create a profile from an owned private JSON file. Gateway generates its stable ID; duplicate names are rejected. |
s3 delete <profile_id> | Remove the stored profile through the gateway lifecycle; provider resources are left unchanged. |
The input file must be an owned private regular file, at most 64 KiB. --file - reads JSON from standard input.
plugins settingsInspect and patch provider configuration stored in PostgreSQL. Secret values remain hidden when reading configuration.
| Command | Purpose |
|---|---|
plugins settings list | List provider configuration metadata. |
plugins settings show <plugin_id> | Read configuration with secret values hidden. |
plugins settings set <plugin_id> --file <path> | Patch values from a private JSON file; - selects standard input. |
plugins settings import-env | Import missing legacy provider settings. Optional --remove-env removes migrated legacy keys from local .env only after successful import. |
These are configuration commands, not Codex plugin package installation. Use setup plugins to install plugin packages. Use Web Admin for profile connection/OAuth where supported.
Use these for explicit foreground operation and diagnostics. Do not run duplicate processes against an already-managed installation. Normal installations should prefer service start.
| Command | Runs |
|---|---|
supervise | The gateway supervisor and its owned API/runtime processes. |
serve | The HTTP API using configured settings. |
runtime | The singleton Codex runtime on its private Unix socket. |
whatsapp-runtime | The isolated WhatsApp runtime. |
automation-runtime | The isolated automation runtime. |
third-party-runtime | The isolated third-party application runtime. |
tools-runtime | The allowlisted runtime-tools process. |
Web Admin's foreground equivalent is admin serve. Gateway runtimes and the external Codex App Server are separate lifecycle owners.
Updates
Run the install.sh command above to get the latest release. Your configuration and data stay in place. The installer runs migrations and restarts managed services; an up-to-date installation is left unchanged.
Distribution
Use the installer to select the correct latest bundle automatically. Archives include the complete application bundle and are accompanied by SHA256SUMS. Homebrew and APT channels are being prepared; no package-manager install command is advertised before publication.
GitHub Releases