Hi *, really enjoying CircleCI, amazing software really.
I have one question though: when building locally using docker-compose I pass my ssh key to Docker to pull gems from github and such.
Here an example Dockerfile:
ARG SSH_KEY
RUN mkdir /root/.ssh/
RUN echo "$SSH_KEY" > /root/.ssh/id_rsa
RUN chmod 600 /root/.ssh/id_rsa
RUN touch /root/.ssh/known_hosts
RUN ssh-keyscan github.com >> /root/.ssh/known_hosts
Here is how I build and launch my services:
docker-compose build --build-arg SSH_KEY="$(cat ~/.ssh/id_rsa)"
docker-compose up --no-build
I’m not entirely sure how can I adapt this workflow to CircleCI and what to put in the config.yml
, but I’m also sure this it quite common. Any suggestion/hint/link?
Thanks in advance,
ngw