How to install Ghost on your hosting account

1 de noviembre, 2015 @ 13:49 — 0 comentarios

Ghost is a free and open source blogging platform written in JavaScript and distributed under the MIT License, designed to simplify the process of online publishing for individual bloggers as well as online publications.

In this guide q¡we explain how to install Ghost in your hosting account using SQLite as database.

1 - Define the application from the Hosting Panel

Access the Hosting Panel and click on NodeJs applications icon. Fill in the form as you see in the following image:

install-nodejs-ghost-1

Once you submit the form you we'll see the app creation result. Take note of the application directory as it's important for the next steps.

install-nodejs-ghost-2

2 - Place Ghost files

Place Ghost files on the application's root folder. If the defined app name is ghost it's root folder will be /home/username/nodejs/ghost

Access your hosting using SSH and run the following to download last avaiable version of Ghost:

cd nodejs/ghost
wget --no-check-certificate https://ghost.org/zip/ghost-0.7.1.zip
unzip ghost-0.7.1.zip

Now you will have all files of the last Ghost version in the correct location.

3 - Adapt Ghost to the required application structure

Ghost includes a file named index.js as application gateway. As explained in our Basic structure of a NodeJS application guide we require the gateway file to be named app.js, therefore we'll create a symbolic lik named app.js that points to index.js:

rm -f app.js
ln -s index.js app.js

4 - Enable access to compilers

In order to install Ghost dependencies you will have to enable access to compilers. Just follow the How to enable access to compilers guide.

5 - Install dependencies

Ghost includes a package.json file so installing it's dependencies is very easy, simply run_:

npm install --production

6 - Setup your Admin account

Just open your favourite web browser and navigate to the domain you selected in the first step ( for example www.youdomain.com ). You will see something like:

install-nodejs-ghost-3

Now that you have verified Ghost is working, you must setup the Admin username, just navigate to www.youdomain.com/ghost and follow instructions. Once you have setup the Admin account you will access directlty to Ghost's admin area:

install-nodejs-ghost-4

Etiquetas: