Exclusive Metin2 game shield on FreeBSD: Automatic siege mode, VIP list, and whitelist from your dashboard. See how it works
Create a server

Guide

How to Set Up BookStack on a VPS

BookStack is a wiki organized as books and chapters. Ideal for internal team docs on your own VPS.

Steps

  1. Create Compose with App + MySQL:

    mkdir -p ~/bookstack && cd ~/bookstack
    sudo tee docker-compose.yml >/dev/null <<'EOF'services:  db:    image: mysql:8.0    environment:      MYSQL_ROOT_PASSWORD: rootpass      MYSQL_DATABASE: bookstack      MYSQL_USER: bookstack      MYSQL_PASSWORD: bookstackpass    volumes:      - db-data:/var/lib/mysql    restart: unless-stopped  bookstack:    image: lscr.io/linuxserver/bookstack:latest    depends_on: [db]    environment:      APP_URL: https://docs.example.com      DB_HOST: db      DB_USER: bookstack      DB_PASS: bookstackpass      DB_DATABASE: bookstack    volumes:      - bs-config:/config    ports:      - "127.0.0.1:6875:80"    restart: unless-stoppedvolumes:  db-data:  bs-config:EOF
  2. Start the stack:

    docker compose up -d
    docker compose ps
  3. Point Nginx + Certbot at 127.0.0.1:6875:

    sudo tee /etc/nginx/sites-available/bookstack >/dev/null <<'EOF'server {  listen 80;  server_name docs.example.com;  location / {    proxy_pass http://127.0.0.1:6875;    proxy_set_header Host $host;    proxy_set_header X-Forwarded-Proto $scheme;  }}EOF
    sudo ln -sf /etc/nginx/sites-available/bookstack /etc/nginx/sites-enabled/bookstack
    sudo nginx -t && sudo systemctl reload nginx
    sudo certbot --nginx -d docs.example.com
  4. Log in and change the default admin password:

    # https://docs.example.com  ([email protected] / password)

Tips

  • Change MYSQL_* and the admin password on first login.
  • Back up volumes db-data and bs-config.

ext step

Team docs on your own VPS: Deploy your Cloud VPS.

Related guides