使用 Ghost 搭建 Blog

This is the programmer's leisure time series!

推荐阅读官网文档,以下步骤来源于个人,不保证广大人们群众也习惯!😀

推荐环境:

  • Ubuntu 16.04
  • MySQL
  • NGINX
  • Systemd
  • Node v6 installed via NodeSource
  • At least 1GB memory (swap can be used)
  • A non-root user for running ghost commands
Create a New User
adduser ghost
Super User Privileges
usermod -aG sudo ghost
Log in as the new user
su - ghost
Update package lists && Upgrade installed packages
sudo apt update; sudo apt upgrade
Install NGINX
sudo apt install nginx
Install MySQL
sudo apt install mysql-server mysql-client
Install Node.js
curl -sL https://deb.nodesource.com/setup_6.x | sudo -E bash 
sudo apt-get install -y nodejs
Install Ghost-CLI
sudo npm i -g ghost-cli
Install Ghost via the CLI
  1. Create a new folder
sudo mkdir -p /var/www/ghost
  1. Your user must own this directory
sudo chown ghost:ghost /var/www/ghost
  1. Navigate to the new folder
cd /var/www/ghost
  1. Install Ghost (using Ghost-CLI)
ghost install
Start Ghost-CLI
ghost start

到此为止,如果大家一切顺利的话,ghost 就已经安装完成了💃

ghost 默认启动端口是 2368,在浏览器中访问 127.0.0.1:2368 就可以看到美丽的ghost了😍
访问 127.0.0.1:2368/ghost 可以进入ghost的后台管理界面👏

接下来贴两张 ghost 的界面给大家瞅瞅~😀

dashboard
detail
edit

Show Comments

Get the latest posts delivered right to your inbox.