Railway

Deploy openstock

OpenStock is an open-source stock monitor platform built with Next.js

Deploy openstock

MongoDB

mongo:8.0

Just deployed

/data/db

Deploy and Host OpenStock on Railway

About Hosting

OpenStock is an open-source stock market web app built with Next.js 15, Better Auth, and MongoDB. It provides watchlists, stock search, news, and chart widgets, plus optional automated email flows through Inngest.

On Railway, the recommended architecture is two services:

  • OpenStock app service (Next.js runtime)
  • MongoDB service (managed Mongo database)

Why Deploy

  • Own your data — host your auth, watchlists, and user preferences privately.
  • Full-stack in one project — app + database managed together in Railway.
  • Open-source flexibility — customize workflows and integrations.
  • Fast setup — Railway handles build and runtime for Next.js quickly.

Common Use Cases

  • Personal or team stock tracking dashboard with custom watchlists.
  • Internal finance/market-monitoring portal for startups and communities.
  • Educational/demo deployment for Next.js + Better Auth + MongoDB architecture.
  • Base project for building custom alerting or AI-assisted market summaries.

Dependencies for Deployment

Deployment Dependencies

DependencyDetails
Docker Imagedocker.io/xiaosong233/openstock:railway-latest (replace with your own tag)
Build ModeLocal Docker build + Docker Hub push
Container Port3000
DatabaseRailway MongoDB service
Required App Env VarsNODE_ENV, MONGODB_URI, BETTER_AUTH_SECRET, BETTER_AUTH_URL, NEXT_PUBLIC_FINNHUB_API_KEY, FINNHUB_BASE_URL, GEMINI_API_KEY, INNGEST_SIGNING_KEY, NODEMAILER_EMAIL, NODEMAILER_PASSWORD
Optional App Env VarsAI_PROVIDER, MINIMAX_API_KEY, KIT_API_KEY, KIT_API_SECRET, KIT_WELCOME_FORM_ID
Persistent VolumeManaged by Railway MongoDB service
Start Command OverrideNot required (use project default npm start)

Template Content

More templates in this category

View Template
Bugsink
Self-hosted Error Tracking. Sentry-SDK compatible

zǝʇɹoɔ oɓıɹpoɹ
View Template
SubTrackr
Self-hosted Subscription Tracker

amnesia
View Template
NEW
Dashy — Open Source Homer & Homarr Alternative on Railway
Self Host Dashy. Open Source Start Page with Widgets & Themes

Heimdall