Deploy FastGPT

AI knowledge base and workflow platform, full stack with pgvector and S3

Deploy FastGPT

Just deployed

/data/db

/data

Just deployed

Just deployed

/data

/var/lib/postgresql/data

Deploy and Host FastGPT on Railway

FastGPT is an open source platform for building AI knowledge bases and agent workflows. You import documents, web pages or APIs into datasets, then build chat apps and visual workflows on top of them with retrieval, HTTP, MCP and code nodes. It works with OpenAI, Anthropic, DeepSeek, Ollama and other OpenAI-compatible providers.

About Hosting FastGPT

FastGPT needs several services: the app, a plugin service, a code sandbox, AI Proxy for model channels, MongoDB as a replica set, Postgres with pgvector, Redis and S3-compatible storage. This template deploys all of them from one GitHub repo, with image versions pinned by digest, data on volumes and every secret generated. There are no prompts. FastGPT normally creates its root admin with the password 123456. This template replaces it with a generated password before the app goes public. After deploy, open the FastGPT service's Variables tab and copy ROOT_PASSWORD. Then open the public URL, log in as root and set your own password. Finally, add a model channel with your provider API key, and enable a chat model and an embedding model.

Common Use Cases

  • Company or product knowledge base chat with cited answers
  • Customer support bots on a website, API or messaging channel
  • Visual AI workflows that mix retrieval, HTTP calls, MCP tools and JavaScript or Python code

Dependencies for FastGPT Hosting

  • FastGPT (public): web app and API, FastGPT v4.17.4
  • FastGPT Plugin: system tools and the model provider catalog
  • Code Sandbox: runs JavaScript and Python code nodes in isolation
  • AI Proxy: stores model channels and provider API keys
  • MongoDB 7.0: apps, datasets, chats and users, as a single-node replica set (volume)
  • Postgres 17 + pgvector: vector search, plus AI Proxy's database (volume)
  • Redis: queues, locks and caches (volume)
  • RustFS: S3-compatible storage for uploaded files and images (volume, private)

Deployment Dependencies

Implementation Details

  • All services except Redis build from aalfath/fastgpt-railway-template, one folder per service. When the template's repo gets a version bump, Railway shows you an "update available" notice; read the repo's CHANGELOG.md before you apply it.
  • Uploads and downloads go through FastGPT itself, so RustFS needs no public domain.
  • Workflow HTTP nodes can't call private addresses (CHECK_INTERNAL_IP=true). Set it to false on the FastGPT service if you need to reach other Railway services.
  • Forgot the root password? Run node /app/scripts/reset-root-password.cjs 'NEW-PASSWORD' in the FastGPT service shell.
  • If you add a custom domain, set FE_DOMAIN on FastGPT to it.
  • Not included: FastGPT's Agent Sandbox (it needs the host Docker socket, which Railway doesn't provide) and the alternative vector stores (Milvus, OceanBase). Everything else works without them.

Why Deploy FastGPT 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 FastGPT 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

More templates in this category

View Template
Chat Chat
Chat Chat, your own unified chat and search to AI platform.

okisdev
117
View Template
Weaviate
Vector database with hybrid search and an API key-protected API

GitHub Locker
1
View Template
Möbius Personal AI OS
Self-hosted AI agent that builds and runs apps for you, with memory.

bento
1