Complete Setup Guide: Ghost Blog on unRAID 2024

Prerequisites

  • unRAID server up and running
  • Community Applications (CA) installed
  • Basic understanding of unRAID’s interface
  • Ports 2368 and 3306 available on your network

Step 1: Prepare Directory Structure

  1. SSH into your unRAID server or use the terminal
  2. Create the necessary directories:
mkdir -p /mnt/user/appdata/ghost/mysql
mkdir -p /mnt/user/appdata/ghost/content
  1. Set proper permissions:
chmod -R 777 /mnt/user/appdata/ghost

Step 2: Set Up MariaDB Container

  1. Open unRAID web interface
  2. Go to the “Docker” tab
  3. Click “Add Container”
  4. Enter the following settings:

Basic Configuration

  • Name: GhostDB
  • Repository: maurosoft1973/alpine-mariadb
  • Network Type: Bridge

Environment Variables

MYSQL_ROOT_PASSWORD=GObrpLskjguwiDoR4lyJzGWUXbl0cY6IOzSMZI1D
MYSQL_DATABASE=ghost
MYSQL_USER=ghost
MYSQL_PASSWORD=91XHfXc0zpJZ8SCTsTheaDW3rm15w17yPGjxHzcL

Path Mappings

  • Config Path: /mnt/user/appdata/ghost/mysql:/var/lib/mysql

Port Mappings

  • Host Port: 3306
  • Container Port: 3306
  1. Click “Apply” to create and start the container
  2. Wait for the container to start and verify it’s running

Step 3: Set Up Ghost Container

  1. In the Docker tab, click “Add Container” again
  2. Enter the following settings:

Basic Configuration

  • Name: Ghost
  • Repository: ghost:5-alpine
  • Network Type: Bridge

Environment Variables

database__client=mysql
database__connection__host=ghost_db
database__connection__user=ghost
database__connection__password=91XHfXc0zpJZ8SCTsTheaDW3rm15w17yPGjxHzcL
database__connection__database=ghost
url=http://YOUR_SERVER_IP:2368

Replace YOUR_SERVER_IP with your actual unRAID server IP address

Path Mappings

  • Content Path: /mnt/user/appdata/ghost/content:/var/lib/ghost/content

Port Mappings

  • Host Port: 2368
  • Container Port: 2368
  1. Click “Apply” to create and start the container

Step 4: Verify Installation

  1. Wait 2-3 minutes for both containers to fully initialize
  2. Check container logs for any errors:
    • Go to Docker tab
    • Click on container name
    • Click “Logs” to view startup messages
  3. Access Ghost admin panel:
    • Open browser
    • Navigate to: http://YOUR_SERVER_IP:2368/ghost
    • Create your admin account on first visit

Step 5: Configure Ghost Settings

  1. Log into Ghost Admin
  2. Go to Settings → General
  3. Update your site title and description
  4. Configure your timezone
  5. Save changes

Security Recommendations

  1. Change default passwords in environment variables
  2. Update the following passwords:
    MYSQL_ROOT_PASSWORD=<your-secure-password>
    MYSQL_PASSWORD=<your-secure-password>
    database__connection__password=<same-as-MYSQL_PASSWORD>
    
  3. Consider setting up SSL/TLS (requires reverse proxy)
  4. Regularly backup your content directory

Backup Instructions

  1. Stop both containers
  2. Backup these directories:
    • /mnt/user/appdata/ghost/mysql
    • /mnt/user/appdata/ghost/content
  3. Start containers

Troubleshooting

Database Connection Issues

  1. Verify MariaDB container is running
  2. Check logs for connection errors
  3. Ensure host names match in environment variables
  4. Verify database credentials

Ghost Not Starting

  1. Check if MariaDB is fully initialized
  2. Verify volume permissions
  3. Check Ghost logs for specific errors

Cannot Access Admin Panel

  1. Verify correct URL in environment variables
  2. Check port forwarding settings
  3. Verify network mode settings

Maintenance Tasks

Regular Updates

  1. Stop both containers
  2. Remove containers (data remains safe in appdata)
  3. Pull new images
  4. Recreate containers with same settings

Database Maintenance

  1. Regular backups
  2. Periodic database optimization
  3. Log rotation

Additional Configuration Options

Email Setup (Optional)

Add these environment variables to Ghost container:

mail__transport=SMTP
mail__options__host=your-smtp-server
mail__options__port=587
mail__options__auth__user=your-email
mail__options__auth__pass=your-password

Custom Theme Installation

  1. Upload theme files to: /mnt/user/appdata/ghost/content/themes
  2. Activate in Ghost Admin → Settings → Design

Performance Optimization

  1. Consider adding cache plugins
  2. Optimize images
  3. Configure proper resource limits

Monitoring

  1. Regular check of container logs
  2. Monitor disk space usage
  3. Check Ghost admin panel for updates
  4. Monitor database performance

Installation Guide for Ghost Blog Via UnRaid Templates

Unraid_app_templates/ghost-cms at main - hhf/unraid_app_templates - HHF Technology Repository

Template Files Setup

  1. Create two files on your local computer:
    • ghost-db.xml - Copy the exact content from the first template
    • ghost.xml - Copy the exact content from the second template

Step 1: Installing the Database Container

  1. Open unRAID web interface
  2. Navigate to the “Docker” tab
  3. Click “Add Container”
  4. Click “Upload” and select your ghost-db.xml file
  5. The form will populate automatically. Verify these exact settings:

Container Settings for GhostDB:

Name: GhostDB
Repository: maurosoft1973/alpine-mariadb
Network Type: bridge

Environment Variables (EXACTLY as shown):

MYSQL_ROOT_PASSWORD=GObrpLskjguwiDoR4lyJzGWUXbl0cY6IOzSMZI1D
MYSQL_DATABASE=ghost
MYSQL_USER=ghost
MYSQL_PASSWORD=91XHfXc0zpJZ8SCTsTheaDW3rm15w17yPGjxHzcL

Path Configuration:

Host Path: /mnt/user/appdata/ghost/mysql
Container Path: /var/lib/mysql
Access Mode: Read/Write

Port Configuration:

Host Port: 3306
Container Port: 3306
  1. Click “Apply”
  2. Wait until container shows as “Running” (approximately 1-2 minutes)
  3. Check logs to confirm successful initialization

Step 2: Installing the Ghost Container

  1. Stay in the Docker tab
  2. Click “Add Container” again
  3. Click “Upload” and select your ghost.xml file
  4. Verify these exact settings:

Container Settings for Ghost:

Name: Ghost
Repository: ghost:5-alpine
Network Type: bridge

Environment Variables (EXACTLY as shown):

database__client=mysql
database__connection__host=ghost_db
database__connection__user=ghost
database__connection__password=91XHfXc0zpJZ8SCTsTheaDW3rm15w17yPGjxHzcL
database__connection__database=ghost
url=http://[IP]:2368

Note: Replace [IP] with your unRAID server’s IP address

Path Configuration:

Host Path: /mnt/user/appdata/ghost/content
Container Path: /var/lib/ghost/content
Access Mode: Read/Write

Port Configuration:

Host Port: 2368
Container Port: 2368

Step 3: Verification Steps

  1. Check Database Container:

    • Status should show “Running”
    • Logs should show “MariaDB init process done. Ready for start up.”
  2. Check Ghost Container:

    • Status should show “Running”
    • Logs should show “Ghost boot process ended”
  3. Access Ghost:

    • Open web browser
    • Navigate to: http://YOUR_UNRAID_IP:2368
    • You should see the default Ghost welcome page
  4. Access Admin Panel:

    • Navigate to: http://YOUR_UNRAID_IP:2368/ghost
    • Create your admin account on first visit

Important Notes About Templates

  1. Template Variables:

    • All environment variables are preset in the templates
    • Database passwords are preset but should be changed
    • URL variable automatically uses your server’s IP
  2. Volume Mappings:

    • Templates automatically create necessary directories
    • Proper permissions are set automatically
    • All data persists in /mnt/user/appdata/ghost/
  3. Network Configuration:

    • Both containers use bridge networking
    • Internal communication is handled automatically
    • Ports 2368 and 3306 must be free on your host
  4. Container Dependencies:

    • Always start GhostDB container first
    • Wait for database initialization before starting Ghost
    • Both containers set to auto-start after reboot

Template Modifications (if needed)

If you need to change any settings, modify these specific sections:

In ghost-db.xml:

<Environment>
    <Variable>
        <Name>MYSQL_ROOT_PASSWORD</Name>
        <Value>YOUR_NEW_ROOT_PASSWORD</Value>
    </Variable>
    <!-- Other variables follow same pattern -->
</Environment>

In ghost.xml:

<Environment>
    <Variable>
        <Name>database__connection__password</Name>
        <Value>YOUR_NEW_PASSWORD</Value>
    </Variable>
    <!-- Other variables follow same pattern -->
</Environment>
1 Like