Heroku : Complete Setup

Heroku Setup For your Rails application  Create Heroku Account

Then you need to install Heroku Gem in your application , if you are using RVM then you need to run

gem install heroku

Or you can use bundler to install heroku by mentioning that in the Gemfile

gem 'heroku'

Then you need to add your Public key to the Heroku Account.

ssh-keygen -t rsa -f ~/.ssh/your_name -C "your-email@domain.com"

You can use this command to create a new pair of public and private keys and you can give keys a unique name , if you are already using a keys and wanted to create a new one.

After that you need to login to heroku from your terminal by using

heroku login

After that you need to enter your email address and password which you have created for your heroku account.

Once you logged in to your Heroku Account from your terminal , you need to add the key which you have created to that account , you can do this by

heroku keys:add /path_to/.ssh/your_name.pub

Once you did that , you can take clone from your heroku repo and if you wanted to push your code you can use

git push heroku master

You also need to add heroku repo to git remote repo list , you can do this by

git remote add heroku git@heroku.com:your_repo.git


Popular posts from this blog

Inserting and Moving elements inside Ruby Array

Find duplicate records in ServiceNow