Please find below simple steps to deploy your ghost blog on Heroku for free.
- Download zip file from Ghost blog
- Unzip it in local folder
- Go to the unzipped folder using command line and run following commands:
npm init
npm install
This will install all dependent modules. Once its done intiate a local Git repository using following command
git init
- Now is the time to create your heroku application using following command
heroku create`
- Cross check if application is created by using following command
git remote -v
- Add postgresql database using following command
heroku addons:add heroku-postgresql:hobby-dev`
You can get the details of the database using following command
heroku config
Database is creating using following convention.
postgres://{POSTGRES_USER}:{POSTGRES_PASS}@{POSTGRES_HOST}:{POSTGRES_PORT}/{POSTGRES_DB}
- Now you are all set, just push these changes to Heroku cloud by using following commands.
git add .
git commit -am "make it better"
git push heroku master
- Go to your heroku account and your Ghost blog is ready for usage.
Additional steps:
If you have a domain name which you want to use for your blog, Heroku allows you to use it even for free account. Use following command to add domain.
heroku domains:add www.optimumportfolio.in
Cross check if domain name is added correctly using following command:
heroku domains