From c97cae76f7255a851480dbe009b1889bd92614ba Mon Sep 17 00:00:00 2001 From: Pawan Mehta <117346502+pawan-mehta-dt@users.noreply.github.com> Date: Wed, 6 Nov 2024 11:35:15 +0530 Subject: [PATCH] Merge pull request #22 from devtron-labs/mirror-fix Fix docker hub rate limiting using GCR mirrors --- ci-runner/Dockerfile | 6 +++++- ci-runner/buildkitd.default.toml | 2 ++ ci-runner/docker-daemon.json | 1 + 3 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 ci-runner/buildkitd.default.toml create mode 100644 ci-runner/docker-daemon.json diff --git a/ci-runner/Dockerfile b/ci-runner/Dockerfile index d89315d04..921701aca 100644 --- a/ci-runner/Dockerfile +++ b/ci-runner/Dockerfile @@ -31,6 +31,10 @@ RUN (curl -sSL "https://github.com/buildpacks/pack/releases/download/v0.27.0/pac COPY --from=build-env /go/bin/cirunner . COPY ./ssh-config /root/.ssh/config RUN chmod 644 /root/.ssh/config +RUN mkdir -p /etc/docker +COPY docker-daemon.json /etc/docker/daemon.json +RUN mkdir -p /root/.docker/buildx +COPY buildkitd.default.toml /root/.docker/buildx/buildkitd.default.toml # passing PARENT_MODE as argument to cirunner as default behavior -ENTRYPOINT ["./cirunner", "PARENT_MODE"] \ No newline at end of file +ENTRYPOINT ["./cirunner", "PARENT_MODE"] diff --git a/ci-runner/buildkitd.default.toml b/ci-runner/buildkitd.default.toml new file mode 100644 index 000000000..3946ff750 --- /dev/null +++ b/ci-runner/buildkitd.default.toml @@ -0,0 +1,2 @@ +[registry."docker.io"] + mirrors = ["mirror.gcr.io"] diff --git a/ci-runner/docker-daemon.json b/ci-runner/docker-daemon.json new file mode 100644 index 000000000..2fee9981a --- /dev/null +++ b/ci-runner/docker-daemon.json @@ -0,0 +1 @@ +{"registry-mirrors": ["https://mirror.gcr.io"]}