Reputation: 1762
Using Capistrano version 3.4.0
repo url set as follows on my deploy.rb file :
set :repo_url, '[email protected]:Username/myProjectName.git'
on my production.rb file:
role :myProjectName, %w{[email protected]}
set :ssh_options, { auth_methods: %w(password), password: "mybitbucketpasswordhere" }
i checked if i can login with my username with ssh -T [email protected]
command:
logged in as Username.
cap production deploy in my project folder and i get following error :
INFO [90fbd4ee] Running /usr/bin/env mkdir -p /tmp/myProjectName/ as [email protected] DEBUG [90fbd4ee] Command: /usr/bin/env mkdir -p /tmp/myProjectName/ (Backtrace restricted to imported tasks) cap aborted! Net::SSH::AuthenticationFailed: Authentication failed for user [email protected]
Tasks: TOP => git:check => git:wrapper (See full trace by running task with --trace) The deploy has failed with an error: Authentication failed for user [email protected]
Where do i go wrong ?
Thanks in advance.
Upvotes: 0
Views: 1604
Reputation: 13952
You've added your SSH Key, which should mean you don't need to provide a password. So this line: set :ssh_options, { auth_methods: %w(password), password: "mybitbucketpasswordhere" }
is incorrect.
I believe the default for capistrano is to use SSH authentication, so try just removing that line.
Upvotes: 1