Deploy Didacta

Didacta Is a Fair-Code Self-Hosted Learning Platform

Deploy Didacta

Just deployed

/data

Just deployed

/var/lib/postgresql/data

/app/data

Deploy on Railway

Deploy and Host Didacta Community on Railway

Didacta Community is a modern, open-source learning management and educational platform designed for creating, managing, and delivering online courses, training modules, and knowledge systems. This Railway template provisions a full three-tier production stack featuring the Didacta Application Server (didacta), a pgvector-enabled PostgreSQL database (postgres), and a Redis cache engine (redis), complete with persistent volume storage and automated secret provisioning.


About Hosting Didacta

Hosting Didacta Community on Railway deploys a robust multi-container architecture:

  • Didacta Core Application (didacta): Node.js web and API application container running ghcr.io/va360labs/didacta-community:0.0.1-alpha.107. It serves both the user-facing web dashboard and API endpoints (listening on web port 3000 and API port 4000), processes file uploads in /app/data/storage, and connects to PostgreSQL and Redis over Railway's internal private network.
  • Vector PostgreSQL Database (postgres): Relational and vector database running pgvector/pgvector:pg16. It handles structured application data and vector embeddings, mounting a persistent storage volume at /var/lib/postgresql/data.
  • Redis In-Memory Cache (redis): Cache and pub/sub message broker running redis:7-alpine. It handles session caching and background job processing, mounting a persistent volume at /data.

Common Use Cases
  • Self-hosted Learning Management System (LMS): Create, manage, and distribute structured online learning courses and training paths.
  • Vector-assisted educational search: Leverage pgvector for semantic search, intelligent AI indexing, and content retrieval across course materials.
  • Internal employee onboarding & knowledge base: Build private training hubs for staff and community members with full data sovereignty.
  • Integrated educational technology stack: Pre-configured database, Redis queues, and persistent local storage out of the box.

Dependencies for Didacta Hosting
  • Didacta Community image: ghcr.io/va360labs/didacta-community:0.0.1-alpha.107
  • PostgreSQL image with pgvector: pgvector/pgvector:pg16
  • Redis image: redis:7-alpine
  • Three persistent volumes:
    • didacta: /app/data (for local file storage and media uploads)
    • postgres: /var/lib/postgresql/data (for database tables and vector indices)
    • redis: /data (for cache state and task queues)
  • Railway public domain mapped to port 3000 for didacta
  • Auto-generated secrets: Cryptographic session secret (AUTH_SECRET), setup token (DIDACTA_SETUP_TOKEN), and database passwords (POSTGRES_PASSWORD)

Upstream: GitHub (va360labs/didacta-community) · Docker Registry (GHCR)

Implementation Details
ServiceImageRoleWeb / Internal PortVolume Mount
didactaghcr.io/va360labs/didacta-community:0.0.1-alpha.107Web UI & API Engine3000 (Web) / 4000 (API)/app/data
postgrespgvector/pgvector:pg16Relational & Vector Database5432/var/lib/postgresql/data
redisredis:7-alpineCache & Job Broker6379/data

Topology
ServiceRoleVolumePublicNotes
didactaMain Application UI & API/app/dataYes (Port 3000)Healthcheck at /healthz
postgresRelational Vector DB/var/lib/postgresql/dataTCP Proxy (Port 5432)pgvector extension enabled
redisCache & Session Store/dataTCP Proxy (Port 6379)Shared password with PostgreSQL
Volumes (drives) — what to mount
ServiceMount pathWhat is stored
didacta/app/dataLocal file uploads, media assets, export archives (/app/data/storage)
postgres/var/lib/postgresql/dataPostgreSQL tables, vector embeddings, course records, user accounts
redis/dataRedis persistent cache, queue state, active session keys

Warning: Do not remove or detach any of the three persistent volumes — deleting volumes will cause permanent loss of uploaded course files, user records, or database indexes during container redeployments.


Quick Start
  1. Click the Deploy on Railway button above.
  2. Sign in (or create a free Railway account) and click Deploy.
  3. Wait 2–3 minutes for all three services (postgres, redis, and didacta) and their persistent volumes to initialize.
  4. Retrieve the initial setup credentials from the didacta service variables (DIDACTA_SETUP_TOKEN or POSTGRES_PASSWORD).
  5. Open the didacta service → Settings → Networking and click the generated public domain URL.
  6. Access the setup wizard / admin login page to complete your initial administrator configuration.

Configuration
Application Variables (didacta)
VariableDefault / SourceDescription / Notes
NODE_ENVproductionNode.js execution environment
DIDACTA_CORE_VERSION0.0.1-alpha.107Core platform version tag
WEB_PUBLIC_URLhttps://${{RAILWAY_PUBLIC_DOMAIN}}Public canonical base URL for the web interface
WEB_PUBLIC_ALLOWED_HOSTS${{RAILWAY_PUBLIC_DOMAIN}}Allowed host headers for security verification
POSTGRES_USERdidactaApplication database username
POSTGRES_PASSWORD${{postgres.POSTGRES_PASSWORD}}Database password referenced from postgres service
POSTGRES_DBdidactaMain application database name
ADMIN_DATABASE_URL${{postgres.DATABASE_URL}}Private database connection URL
REDIS_URL${{redis.REDIS_URL}}Private Redis connection URL
AUTH_SECRETAuto-generated secret (64 chars)Cryptographic secret key for session signing
DIDACTA_SETUP_TOKEN${{postgres.POSTGRES_PASSWORD}}Token required for initial administrative setup
STORAGE_DRIVERlocalFile storage adapter (local or S3)
STORAGE_ROOT/app/data/storageRoot path for stored file assets inside volume
PORT3000HTTP port exposed to Railway router
Database Variables (postgres)
VariableDefault / SourceDescription / Notes
POSTGRES_DBrailwayInitial system database created on startup
POSTGRES_USERpostgresSuperuser database account
POSTGRES_PASSWORDAuto-generated secret (32 chars)Master database password
DATABASE_URLPrivate connection URLInternal network database string
DATABASE_PUBLIC_URLTCP Proxy URLExternal connection URL for administrative tools
Redis Variables (redis)
VariableDefault / SourceDescription / Notes
REDIS_PASSWORD${{postgres.POSTGRES_PASSWORD}}Shared authentication password
REDIS_URLPrivate connection URLInternal Redis connection string
REDIS_PUBLIC_URLTCP Proxy URLExternal connection string via TCP proxy
Custom Domain
  1. Open the didacta service → Settings → Networking → Custom Domain.
  2. Add your custom domain (e.g. lms.yourdomain.com) and update your DNS CNAME record per Railway instructions.
  3. Update WEB_PUBLIC_URL to https://lms.yourdomain.com.
  4. Update WEB_PUBLIC_ALLOWED_HOSTS to lms.yourdomain.com.
  5. Railway automatically issues and renews TLS certificates.

Updating Didacta
  1. Open the didacta service → Settings → Source.
  2. Update the image tag (e.g., ghcr.io/va360labs/didacta-community:0.0.1-alpha.107 to a newer version tag).
  3. Click Redeploy.

All uploaded files (/app/data), database records (/var/lib/postgresql/data), and cache state (/data) will remain safe across updates.


Traps

Common pitfalls and failure modes:

  • Host Header Mismatch (WEB_PUBLIC_ALLOWED_HOSTS) — If you attach a custom domain without updating WEB_PUBLIC_ALLOWED_HOSTS and WEB_PUBLIC_URL, Didacta will reject web traffic with host security errors or broken redirect URLs.
  • Database Volume Detachment — Ensure all three volume mounts (/app/data, /var/lib/postgresql/data, /data) remain attached. Removing the /app/data volume will delete uploaded course assets and media files.
  • Database Initialization Order — On first boot, didacta requires postgres to be ready. If didacta fails during initial migration, wait for postgres healthchecks to pass and trigger a redeploy on didacta.
  • Private Network vs TCP Proxy Connections — Ensure ADMIN_DATABASE_URL and REDIS_URL point to private domain URLs rather than public TCP proxy domains for lower latency and better security.

Why Deploy Didacta on Railway?

Railway provides a complete platform for hosting multi-container web applications, vector databases, and Redis caches. Deploying Didacta Community on Railway gives you private service networking, persistent volume storage, auto-generated cryptographic keys, automatic HTTPS termination, and zero-maintenance cloud hosting.



Template Content

More templates in this category

View Template
Rocky Linux
Hosted Rocky Linux 9 workspace with SSH and persistent storage. 🚀

codestorm
47
View Template
Foundry Virtual Tabletop
A Self-Hosted & Modern Roleplaying Platform

Lucas
71
View Template
Letta Code Remote
Run a Letta Code agent 24/7. No inbound ports, just deploy.

Letta
51