How to Install Ghost on Dreamhost


  1. Signup for Dreamhost's VPS service
  2. Once you are logged into the Dreamhost cPanel, on the left hand side, click on "VPS" and then "Enable VPS Service". It may take a little bit for Dreamhost to create your VPS, but once its ready, you will see a code that looks like this ps226308. Copy that code, you will need it in a minute
  3. Now on the left hand side, click on "VPS" and then "Manage Admin Users"
  4. Add a new user with SSH access

    Install Ghost Dreamhost

5. Now open up Terminal or your command line appliction and type the following command, replacing testghost with your username from earlier (it may take a few minutes for your username to propagate):

ssh testghost@ps226308.dreamhostps.com

6. Once in, update the Dreamhost VPS operating system:

sudo apt-get update
sudo aptitude install build-essential zip

7. Download and install Node.js

curl -sL https://deb.nodesource.com/setup | sudo bash -
sudo apt-get install -y nodejs

9. Download and Install Ghost

sudo mkdir -p /var/www/
cd /var/www/
curl -L -O https://ghost.org/zip/ghost-latest.zip
sudo unzip -d ghost [Name-of-Ghost-zip].zip
cd ghost/
sudo npm install --production

10. Edit the config file:

cp config.example.js config.js
to
sudo vi config.js

11. In the "Production" section, change the following:

host: '127.0.0.1',
host: '0.0.0.0',

12. Create Ghost User:

sudo adduser --shell /bin/bash --gecos 'Ghost application' ghost
sudo chown -R ghost:ghost /var/www/ghost/

13. Log into Ghost User:

su - ghost
cd /var/www/ghost/

14. Start Ghost:

npm start --production

15. Browse to your DreamHost URL with `:2368` at the end of the url to see it running (replacing `ps226308` with your DreamHost generated ID from earlier): http://ps226308.dreamhostps.com:2368

Proxy from Port 80 and Keep Ghost Running

There you have it, Node.js is installed, Ghost files are located in /var/www/ghost, and Ghost has been started. You can keep Ghost the way it is currently setup if you do not mind adding :2368 to the end of your url, but we would highly recommend you check out the following two articles to help get your Ghost blog ready:

  • How to Proxy Port 80 to 2368 for Ghost with Nginx

  • Keep Ghost Running with PM2
  • Next Steps:

    Learn Ghost from the Ground Up
    Head to "Ghost for Beginners" to learn everything you need to know about learning and customizing Ghost

    Find the Perfect Ghost Theme
    Go to our Ghost themes section of this site to browse all of your Ghost theme options in one place.