diff --git a/docker/runner.Dockerfile b/docker/runner.Dockerfile index 8ac8c6e9a..818b83dae 100644 --- a/docker/runner.Dockerfile +++ b/docker/runner.Dockerfile @@ -44,6 +44,15 @@ RUN adduser --disabled-password --gecos "" --uid $RUNNER_UID runner \ && usermod -aG docker runner \ && echo "%sudo ALL=(ALL:ALL) NOPASSWD:ALL" > /etc/sudoers \ && echo "Defaults env_keep += \"DEBIAN_FRONTEND\"" >> /etc/sudoers + +# GitHub ssh keys +RUN mkdir -p /home/runner/.ssh \ + && chmod 700 /home/runner/.ssh \ + && ssh-keyscan github.com >> /home/runner/.ssh/known_hosts + +# Adjust permissions +RUN chown -R runner:runner /home/runner + ENV HOME=/home/runner USER runner WORKDIR /home/runner