
Deploy Plexus
Unified API gateway for multiple AI providers.
Plexus
Just deployed
/app/data
Deploy and Host Plexus on Railway
Plexus is a high-performance API gateway that unifies multiple AI providers—OpenAI, Anthropic, Google Gemini, DeepSeek, Groq, and any OpenAI-compatible endpoint—behind a single API surface. Switch models and providers without rewriting client code, while gaining built-in protocol translation, load balancing, usage tracking, and per-key quota enforcement.
About Hosting Plexus
Hosting Plexus requires running a containerized service alongside a persistent database. On Railway, you can deploy the official ghcr.io/mcowger/plexus image alongside a PostgreSQL database service. You must set a DATABASE_URL pointing to your Postgres instance and an ADMIN_KEY for the built-in management dashboard. Once running, Plexus exposes port 4000 for API requests (chat completions, embeddings, transcriptions, and more) and a web UI for configuring providers, model aliases, and API keys. For production workloads, set an ENCRYPTION_KEY to enable AES-256-GCM encryption for secrets and tokens at rest.
Common Use Cases
- Unified AI API endpoint — Route requests from OpenAI, Anthropic, or Gemini clients to any supported backend through a single, compatible gateway
- Intelligent failover & cost optimization — Automatically fall back between providers using random, cost, latency, or performance-based selectors with exponential-backoff cooldowns
- Quota & usage governance — Enforce per-API-key rate limits, token caps, and dollar-spending quotas across all providers from one dashboard
Dependencies for Plexus Hosting
- PostgreSQL database — Add a Railway PostgreSQL service and link it to the Plexus service for persistent usage data and configuration storage
- Container image — Use the official
ghcr.io/mcowger/plexus:latestimage or build from the repository source
Deployment Dependencies
Implementation Details
Required environment variables for Railway deployment:
DATABASE_URL=${{Postgres.DATABASE_URL}}
ADMIN_KEY=
ENCRYPTION_KEY= # Optional but strongly recommended
The service listens on port 4000. Railway's internal networking and automatic HTTPS will handle external routing once the health check passes on the exposed port.
Why Deploy Plexus on Railway?
Railway is a singular platform to deploy your infrastructure stack. Railway will host your infrastructure so you don't have to deal with configuration, while allowing you to vertically and horizontally scale it.
By deploying Plexus on Railway, you are one step closer to supporting a complete full-stack application with minimal burden. Host your servers, databases, AI agents, and more on Railway.
Template Content