MCPcopy Index your code
hub / github.com/OpeOginni/gitterm

github.com/OpeOginni/gitterm @v0.10.0

Chat with this repo
repository ↗ · DeepWiki ↗ · release v0.10.0 ↗ · + Follow
1,842 symbols 4,090 edges 262 files 190 documented · 10%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

GitTerm

Run your coding agent in the cloud. GitTerm runs Opencode in remote workspaces on the cloud provider or sandbox of your choice, so you can code from any device with your own model keys.

Deploy on Railway

What GitTerm does

  • Runs Opencode in cloud workspaces across multiple providers
  • Opens the Opencode TUI in your browser through TTYD
  • Gives you server-only Opencode URLs for desktop or local clients
  • Exposes any workspace port behind a shareable URL, so you can preview and test your app live
  • Keeps your model keys yours (bring your own keys, no markup)

Deploy on Railway

The fastest way to self-host:

  1. Click the deploy button above.
  2. Set the required env vars Railway asks for, especially ADMIN_EMAIL and ADMIN_PASSWORD.
  3. If you want subdomain routing, give the proxy service a wildcard domain like *.your-domain.com.
  4. Configure your workspace providers in the admin panel before users create workspaces.

Services

Required services:

Service Purpose
PostgreSQL Database
Redis Cache and pub/sub
server Main API
web Dashboard and auth UI
proxy Caddy reverse proxy
listener Webhook and event ingress
worker Background jobs

Worker cron jobs:

Worker Schedule Purpose
idle-reaper */10 * * * * Stops idle workspaces and enforces quotas
daily-reset 0 0 * * * Logs daily usage stats once per day

Routing

Caddy can route workspaces either by path or subdomain:

https://your-domain.com/ws/{workspace-subdomain}/
https://{workspace-subdomain}.your-domain.com
https://{port}-{workspace-subdomain}.your-domain.com

Use path routing when you do not control wildcard DNS. Use subdomain routing for apps that rely on relative asset paths.

Open a port on a running workspace to get a live, shareable URL like https://{port}-{workspace-subdomain}.your-domain.com. This is handy for previewing a dev server or sharing a running app while an agent works on it.

Providers

GitTerm can run workspaces on any of these providers. Configure each one in the admin panel before users create workspaces. Click a provider for its full setup guide.

Provider Type Webhook Setup guide
Railway Compute Yes Guide
AWS Compute No Guide
E2B Sandbox Yes Guide
Daytona Sandbox No Guide
Cloudflare Sandbox Sandbox No Guide

SPONSORED BY E2B FOR STARTUPS

Field definitions for every provider live in packages/schema/src/provider-registry.ts.

Webhook Base URL

Providers that use webhooks send events to the GitTerm listener. The endpoint depends on how you expose GitTerm:

  • Through the public proxy: https://<your-base-domain>/listener/trpc/...
  • Directly to the listener service: https://<listener-base-url>/trpc/...

If your listener service is not public, use the proxy form. Exact endpoints are in each provider guide.

GitHub Integration

GitHub integration is optional. It allows users to connect repositories and perform git actions from their workspaces.

Set these env vars on the server service:

  • GITHUB_APP_ID
  • GITHUB_APP_PRIVATE_KEY
  • GITHUB_APP_CLIENT_ID (for login with the same GitHub App)
  • GITHUB_APP_CLIENT_SECRET (for login with the same GitHub App)

Set GITHUB_APP_ID and GITHUB_APP_PRIVATE_KEY together for repo integration. Set GITHUB_APP_CLIENT_ID and GITHUB_APP_CLIENT_SECRET if GitHub login is enabled. A separate GitHub OAuth App is not required.

GitHub App setup:

  • Callback URL: https://<base-domain>/api/auth/callback/github
  • Setup URL: https://<api-url>/api/github/callback
  • Webhook via proxy: https://<your-base-domain>/listener/trpc/github.handleInstallationWebhook
  • Webhook via listener: https://<listener-base-url>/trpc/github.handleInstallationWebhook

Development

See CONTRIBUTING.md for local setup and service URLs.

Common commands:

bun run dev
bun run build
bun run check-types
bun run db:push
bun run db:studio
bun run db:generate
bun run db:migrate

Links

  • Website: https://gitterm.dev
  • OpenCode: https://opencode.ai
  • GitHub: https://github.com/OpeOginni/gitterm

License

MIT. See LICENSE.

Disclaimer

GitTerm is an independent project and is not affiliated with, endorsed by, or sponsored by Opencode or its maintainers. "Opencode" and any related names or marks belong to their respective owners.

Extension points exported contracts — how you extend this code

ComputeProvider (Interface)
(no doc) [10 implementers]
packages/api/src/providers/compute.ts
RateLimitConfig (Interface)
(no doc)
packages/redis/src/types.ts
ProviderConfigField (Interface)
(no doc)
packages/schema/src/provider-registry.ts
CloudProvidersshAccessSupport (Interface)
(no doc)
packages/db/src/schema/cloud.ts
AuthFormProps (Interface)
(no doc)
apps/web/src/components/auth/auth-form.tsx
ServiceWorkerGlobalScope (Interface)
* The **`ServiceWorkerGlobalScope`** interface of the Service Worker API represents the global execution context of a se
packages/api/worker-configuration.d.ts
RateLimitResult (Interface)
(no doc)
packages/redis/src/types.ts
ProviderDefinition (Interface)
(no doc)
packages/schema/src/provider-registry.ts

Core symbols most depended-on inside this repo

error
called by 256
packages/api/worker-configuration.d.ts
cn
called by 151
apps/web/src/lib/utils.ts
log
called by 140
packages/api/worker-configuration.d.ts
input
called by 115
packages/api/worker-configuration.d.ts
set
called by 107
packages/api/worker-configuration.d.ts
get
called by 79
packages/api/worker-configuration.d.ts
send
called by 62
packages/api/worker-configuration.d.ts
info
called by 60
packages/api/worker-configuration.d.ts

Shape

Function 703
Interface 488
Method 448
Class 133
Enum 70

Languages

TypeScript100%

Modules by API surface

packages/api/worker-configuration.d.ts633 symbols
packages/api/src/providers/railway/graphql/generated/railway.ts86 symbols
packages/api/src/providers/aws/index.ts68 symbols
packages/api/src/service/github/index.ts37 symbols
packages/api/src/providers/e2b/index.ts34 symbols
packages/api/src/providers/daytona/index.ts31 symbols
packages/api/src/providers/cloudflare/compute-provider.ts28 symbols
packages/api/src/service/credentials/model-credentials.ts26 symbols
apps/web/src/components/ui/sidebar.tsx25 symbols
packages/api/src/service/config/provider-config.ts24 symbols
packages/api/src/providers/compute.ts23 symbols
packages/api/src/providers/cloudflare/sandbox-worker/src/index.ts21 symbols

For agents

$ claude mcp add gitterm \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page