Deploy Livebook
Interactive Elixir notebooks for code, data and automation, data on volume
Just deployed
/data
Deploy and Host Livebook on Railway
Livebook is an open-source web app for interactive, collaborative Elixir notebooks. Notebooks are plain Markdown files (.livemd) with code cells that run on demand, and Smart cells query databases, plot charts, build maps and run machine-learning models. Notebooks can also be deployed as small internal web apps.
About Hosting Livebook
This template runs Livebook 0.19.10 from the official image, pinned by version and digest and built from our GitHub repository, as one service with a public HTTPS domain and a health check on /public/health. Everything Livebook keeps lives on a Railway volume at /data: your notebooks, Livebook's own settings (secrets, hubs, file systems) and the Mix.install package cache, so all of it survives redeploys and updates. The login password and the session signing key are generated per deploy. After deploying, open the URL and log in with LIVEBOOK_PASSWORD from the service's Variables tab. Heavy notebooks need more memory.
Common Use Cases
- Exploring data and prototyping Elixir code in shareable notebooks
- Automating code and data workflows, such as database queries, reports and scheduled jobs
- Running machine-learning models with Nx and Bumblebee, or publishing notebooks as internal apps
Dependencies for Livebook Hosting
- The official Livebook image (
ghcr.io/livebook-dev/livebook), wrapped by aalfath/livebook-railway-template - A Railway volume mounted at
/data
Deployment Dependencies
- Livebook on GitHub and its environment variables
- Livebook 0.19.10 release notes
- Template repository and changelog
Implementation Details
Nothing to fill in at deploy time. The template sets three variables:
PORT:8080, the port the public domain points at.LIVEBOOK_PASSWORD: generated, 24 characters. Change it (12+ characters) in the Variables tab and redeploy.LIVEBOOK_SECRET_KEY_BASE: generated, 64 characters, so logins survive redeploys.
Optional: set LIVEBOOK_IDENTITY_PROVIDER to sign in through Cloudflare Access, Google IAP or Tailscale instead of a password, or LIVEBOOK_APPS_PATH (for example /data/apps) to deploy notebooks as apps on startup. Rich outputs load from upstream's livebookusercontent.com sandbox origin over HTTPS, which is Livebook's normal behaviour.
Updates: the template builds from our GitHub repository, so when we bump the pinned version Railway shows an "update available" notice on your project and you choose when to apply it. Read the repository's CHANGELOG first; your notebooks stay on the volume.
Why Deploy Livebook 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 Livebook 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
