Browse Source

Add Docker Hub registry mirror to avoid rate limits

pull/7444/merge
Chris Lu 2 days ago
parent
commit
8102fb5642
  1. 8
      .github/workflows/container_dev.yml
  2. 7
      .github/workflows/container_latest.yml
  3. 8
      .github/workflows/container_release1.yml

8
.github/workflows/container_dev.yml

@ -34,11 +34,19 @@ jobs:
- -
name: Set up QEMU name: Set up QEMU
uses: docker/setup-qemu-action@c7c53464625b32c7a7e944ae62b3e17d2b600130 # v1 uses: docker/setup-qemu-action@c7c53464625b32c7a7e944ae62b3e17d2b600130 # v1
-
name: Create BuildKit config
run: |
cat > /tmp/buildkitd.toml <<EOF
[registry."docker.io"]
mirrors = ["https://mirror.gcr.io"]
EOF
- -
name: Set up Docker Buildx name: Set up Docker Buildx
uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v1 uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v1
with: with:
buildkitd-flags: "--debug" buildkitd-flags: "--debug"
buildkitd-config: /tmp/buildkitd.toml
- -
name: Login to Docker Hub name: Login to Docker Hub
if: github.event_name != 'pull_request' if: github.event_name != 'pull_request'

7
.github/workflows/container_latest.yml

@ -58,10 +58,17 @@ jobs:
- name: Set up QEMU - name: Set up QEMU
if: matrix.qemu if: matrix.qemu
uses: docker/setup-qemu-action@v3 uses: docker/setup-qemu-action@v3
- name: Create BuildKit config
run: |
cat > /tmp/buildkitd.toml <<EOF
[registry."docker.io"]
mirrors = ["https://mirror.gcr.io"]
EOF
- name: Set up Docker Buildx - name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3 uses: docker/setup-buildx-action@v3
with: with:
buildkitd-flags: "--debug" buildkitd-flags: "--debug"
buildkitd-config: /tmp/buildkitd.toml
- name: Login to Docker Hub - name: Login to Docker Hub
if: github.event_name != 'pull_request' if: github.event_name != 'pull_request'
uses: docker/login-action@v3 uses: docker/login-action@v3

8
.github/workflows/container_release1.yml

@ -53,8 +53,16 @@ jobs:
- name: Set up QEMU - name: Set up QEMU
if: matrix.qemu if: matrix.qemu
uses: docker/setup-qemu-action@v3 uses: docker/setup-qemu-action@v3
- name: Create BuildKit config
run: |
cat > /tmp/buildkitd.toml <<EOF
[registry."docker.io"]
mirrors = ["https://mirror.gcr.io"]
EOF
- name: Set up Docker Buildx - name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3 uses: docker/setup-buildx-action@v3
with:
buildkitd-config: /tmp/buildkitd.toml
- name: Login to Docker Hub - name: Login to Docker Hub
if: github.event_name != 'pull_request' if: github.event_name != 'pull_request'
uses: docker/login-action@v3 uses: docker/login-action@v3

Loading…
Cancel
Save