Here is the workflow I want to achieve:
- commit code
- bitbucket pipeline run test on my public docker image
- bitbucket pipeline executes ansible script to deploy on my public docker image
The first 2 steps working fine, but here is the problem: How/Where should I store my private keys to allow ansible to ssh to my remote server via ssh agent?
I am a bit reluctant to store the private key inside Pipeline env settings, since everyone else has admin access to the repo can see it.
There is a similar question asked here but the answer suggests to setup the keys on docker and use private repo, which it's a bit different to mine.