Railway

Deploy BookStack

Deploy BookStack on Railway. Alternative to Notion/Confluence. One click.

Deploy BookStack

Just deployed

Just deployed

/var/lib/mysql

Deploy and Host BookStack on Railway

Deploy on Railway

BookStack is an open-source documentation platform designed for organizing and storing information in a structured and user-friendly way. It works like a modern knowledge base or internal wiki, allowing teams to create books, chapters, and pages to document processes, systems, and knowledge.

With BookStack you can quickly build internal documentation, technical guides, knowledge bases, and collaborative documentation portals.

About Hosting BookStack

Hosting BookStack requires a MySQL or MariaDB database for storing application data such as users, pages, permissions, and revisions. The application stores uploaded images and attachments on local persistent storage.

The container runs an Nginx web server and PHP application internally. Railway handles networking, TLS certificates, and service orchestration.

BookStack listens on port 80 inside the container, which must be exposed to Railway via the PORT environment variable.

Common Use Cases

  • Internal documentation for development teams
  • Knowledge bases for support teams
  • Product documentation and guides
  • Company wikis and onboarding documentation
  • API documentation and developer portals

Dependencies for BookStack Hosting

BookStack requires the following services:

  • MySQL or MariaDB (application database)
  • Persistent storage volume (for uploaded images and attachments)

Optional services:

  • SMTP server (for password reset emails and notifications)
  • Redis (for caching and queues in larger deployments)

Deployment Dependencies

Implementation Details

Environment variables (use Railway reference syntax when deploying):

VariableValue
APP_URLhttps://${{RAILWAY_PUBLIC_DOMAIN}}
APP_KEY${{secret(32, "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789")}}
DB_HOST${{MySQL.MYSQLHOST}}
DB_PORT${{MySQL.MYSQLPORT}}
DB_DATABASE${{MySQL.MYSQLDATABASE}}
DB_USERNAME${{MySQL.MYSQLUSER}}
DB_PASSWORD${{MySQL.MYSQLPASSWORD}}

Storage

BookStack stores uploaded files and attachments on the filesystem.

Create a persistent volume mounted at:

/config

This ensures that uploaded images, attachments, and configuration persist across redeployments.

Quick Start (Local Development)

To run BookStack locally with Docker:

docker run -d \
  -p 8080:80 \
  -e APP_URL=http://localhost:8080 \
  -e DB_HOST=mysql \
  -e DB_DATABASE=bookstack \
  -e DB_USERNAME=bookstack \
  -e DB_PASSWORD=password \
  linuxserver/bookstack

Then access the application at:

http://localhost:8080

First Login

After deploying BookStack, open the public Railway URL.

The system ships with a default administrator account:

Email:

admin@admin.com

Password:

password

Once logged in, you should immediately change the default password:

  1. Click the profile icon in the top-right corner
  2. Open Edit Profile
  3. Change the password

You can then create additional users and manage permissions via:

Settings → Users

Why Deploy BookStack on Railway?

Railway provides a simple platform to deploy and manage infrastructure without needing to configure servers manually.

By deploying BookStack on Railway you get:

  • Managed networking and TLS
  • Integrated MySQL database provisioning
  • Persistent storage
  • Easy redeployments and scaling
  • Simple environment variable configuration

Railway allows you to run your documentation platform alongside your application stack, APIs, databases, and automation services in a single environment.


Template Content

More templates in this category

View Template
Pixelfed
Explore + Share beautiful photos and videos on the Fediverse

Evan Boehs
View Template
NodeBB
Node.js based forum software built for the modern web

Six
View Template
WordPress + MySQL
Zero Config | One click | WordPress | Docker | MySQL

YAV.AI