Leave a comment

Capistrano Deployment Using Local SSH key

Here is the steps to deploy the Application using SSH keys without Password

$ ssh-copy-id user@remote-host

Then you can login to Remote Host using  command without password as :

$ ssh user@remote-host

After this done open the deploy.rb of your Application file and add the following line in your deploy.rb

set :user, ‘amit’

set :ssh_options, {:forward_agent => true}

set :ssh_options, {:keys => [File.join(ENV[“HOME”], “.ssh”, “id_rsa”)]}

set :use_sudo, false

default_run_options[:pty] = true

and its Done  🙂


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: