Ghost
Ghost is an open-source platform specifically designed for creating, managing, and publishing content, such as blogs, magazines, or news websites. Built using Node.js, Ghost offers fast performance, a simple interface, and powerful tools for writers and content publishers. Ghost is known for its ability to support dynamic content, built-in SEO integration, and support for email marketing and monetization through paid subscriptions. With a focus on providing an optimal writing experience, Ghost provides an intuitive and flexible editor. The platform can be self-hosted or hosted through the official Ghost hosting service (Ghost(Pro)). Ghost is often chosen by developers, writers, and organizations seeking a modern publishing solution without unnecessary complexity.
1. System Requirements
System requirements for running Ghost 5:
- OS Ubuntu 22.04
- Nginx web server
- Node.js 20
- MySQL 8
- Systemd
- 1 GB RAM
Before starting the deployment, prepare:
- A VPS or server with Ubuntu 22.04 OS
- SSH access to the server
- A domain already pointed to the server
2. Server Preparation
Update the system
sudo apt update
sudo apt upgrade -y
Install Nginx
sudo apt install nginx -y
Install MySQL
sudo apt install mysql-server -y
Set the MySQL root password
sudo mysql
ALTER USER 'root'@'localhost' IDENTIFIED WITH 'mysql_native_password' BY 'rahasia';
FLUSH PRIVILEGES;
exit
Install Node.js 20
sudo apt install ca-certificates curl gnupg -y
sudo mkdir -p /etc/apt/keyrings
curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | sudo gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg
echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_20.x nodistro main" | sudo tee /etc/apt/sources.list.d/nodesource.list
sudo apt update
sudo apt install nodejs -y
3. Install Ghost
Install ghost-cli
sudo npm install ghost-cli@latest -g
Create a directory for Ghost
sudo mkdir -p /var/www/contoh.com
sudo chown $USER:$USER /var/www/contoh.com
sudo chmod 775 /var/www/contoh.com
cd /var/www/contoh.com
Install Ghost
ghost install
Enter the URL, MySQL root password, and confirm the configuration settings.
? Enter your blog URL: https://www.contoh.com
? Enter your MySQL hostname: 127.0.0.1
? Enter your MySQL username: root
? Enter your MySQL password: [hidden]
? Enter your Ghost database name: contohcom
? Do you wish to set up "ghost" mysql user? (Y/n) y
? Do you wish to set up Nginx? (Y/n) y
? Do you wish to set up SSL? (Y/n) y
? Enter your email (For SSL Certificate) [email protected]
? Do you wish to set up Systemd? (Y/n) y
? Do you want to start Ghost? (Y/n) y
If the installation is complete, a message like the one below will be displayed.
Ghost was installed successfully! To complete setup of your publication, visit:
https://www.contoh.com/ghost/
4. Create Admin Account
Access https://www.contoh.com/ghost
Enter the Site title
, Full name
, Email address
, and Password
.
Then click Create account & start publishing
.