Running Ghost on Ubuntu
Ghost blogging platform was released to public on Oct 14, 2013. It’s a nodejs app, that was started out as a kickstarter.
Since it’s out for public download, I tried to deploy it on a droplet from Digital Ocean running Ubuntu 13.04.
Firstly, Ubuntu repository does not have the latest version of nodejs. Ghost requires nodejs later than 0.8, while nodejs in Ubuntu is 0.68. I had to install nodejs from ppa and later proxy though my current nginx server.
1 2 3 4 |
sudo apt-get install python-software-properties sudo add-apt-repository ppa:chris-lea/node.js sudo apt-get update sudo apt-get install nodes |
These are the steps required to make it work:
(Initial requirement is that you already have nginx server setup and running).
- SSH into your machine and download the file from https://en.ghost.org/download.
- Unzip the file into a directory.
- Then run “npm install –production”
(If you don’t have the latest version of npm, it will throw errors) - In your nginx server definition, add this location:
[bash]location / {
proxy_pass http://127.0.0.1:2368;
proxy_set_header Host $host;
proxy_buffering off;
}[/bash] - Then re-start your nginx and from the Ghost installation directory run “npm start”
- You should see something like this, if everything is okay:
12345678$ npm start> ghost@0.3.2 start /home/msoe/public_html/ghost> node indexGhost is running...Listening on 127.0.0.1:2368Url configured as: http://my-ghost-blog.comCtrl+C to shut down - Now try to access, through your nginx server. You should start seeing console is logging requests coming in.
This document is based on Ghost’s deployment guide.