I'm facing a problem to deploy code from GitHub.
I have a 3 servers :
- Rundeck is running as Docker container on my first server
- Capistrano is running in a second server
- A third server has to receive the GitHub code
Rundeck has a job to connect to Capistrano (through node) and call the cap command to deploy.
From my production.rb file:
set :ssh_options, {
forward_agent: true,
auth_methods: ['publickey']
}
So the Rundeck SSH key must be used from start to the end I think.
The result is:
git@github.com: Permission denied (publickey).
Rundeck connects to Capistrano which connects to my final server. The last step with GitHub is the problem. I have declared my key to deploy key for my project.
When I try from the capistrano server to deploy, no problem at all, I even try different keys and everything works.
Capistrano debug information does not display which key is used. I hope you can help me with annysuggesitions.
Thanks in advance.
Vincent