https://docs.ghost.org/docs/working-with-ghost
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install nginx
sudo ufw allow 'Nginx Full'
sudo apt-get install mysql-server
curl -sL https://deb.nodesource.com/setup_6.x | sudo -E bash
sudo apt-get install -y nodejs
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
sudo apt-get update && sudo apt-get install yarn
sudo npm update -g npm
sudo npm install -g grunt-cli
git clone https://github.com/TryGhost/Ghost.git
cd Ghost
#only do once
yarn run init
#in case of node version not match
please refer to:
https://docs.ghost.org/docs/supported-node-versions
knex-migrator init
# install if needed
npm install -g knex-migrator
Warning "root" does not have permission to access the dev dir
npm install --unsafe-perm -g knex-migrator npm install -g ember-cli npm install -g bower npm install -g watchman
#default configuration
core/server/config/defaults.json
#developer ghost
grunt dev
Running "dev" task
Running "bgShell:client" (bgShell) task
Running "express:dev" (express) task
Starting background Express server
Running "subgrunt:watch" (subgrunt) task
[2017-11-03 03:23:50] INFO Ghost is running in development...
Running "watch" task
Waiting...
[2017-11-03 03:23:50] INFO Listening on: 127.0.0.1:2368
[2017-11-03 03:23:50] INFO Url configured as: http://localhost:2368/
[2017-11-03 03:23:50] INFO Ctrl+C to shut down
[2017-11-03 03:23:50] INFO Ghost boot 2.303s
No comments:
Post a Comment