Skip to content

Commit

Permalink
update: push multi-arch images to a single repo
Browse files Browse the repository at this point in the history
  • Loading branch information
he-sb authored Jan 31, 2023
1 parent 80d10a9 commit 5ba35b4
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/build_cadvidor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ jobs:
push: true
build-args: CADVISOR_VERSION=${{ github.event.inputs.cadvisor_version }}
tags: |
${{ secrets.DOCKERHUB_USERNAME }}/cadvisor-arm64:latest
${{ secrets.DOCKERHUB_USERNAME }}/cadvisor-arm64:${{ github.event.inputs.cadvisor_version }}
${{ secrets.DOCKERHUB_USERNAME }}/cadvisor:latest-arm64
${{ secrets.DOCKERHUB_USERNAME }}/cadvisor:${{ github.event.inputs.cadvisor_version }}-arm64
build-amd64-version:
runs-on: ubuntu-latest
Expand All @@ -62,8 +62,8 @@ jobs:
push: true
build-args: CADVISOR_VERSION=${{ github.event.inputs.cadvisor_version }}
tags: |
${{ secrets.DOCKERHUB_USERNAME }}/cadvisor-amd64:latest
${{ secrets.DOCKERHUB_USERNAME }}/cadvisor-amd64:${{ github.event.inputs.cadvisor_version }}
${{ secrets.DOCKERHUB_USERNAME }}/cadvisor:latest-amd64
${{ secrets.DOCKERHUB_USERNAME }}/cadvisor:${{ github.event.inputs.cadvisor_version }}-amd64
combine-two-images:
runs-on: ubuntu-latest
Expand All @@ -80,8 +80,8 @@ jobs:

- name: Combine two images
run: |
docker manifest create ${{ secrets.DOCKERHUB_USERNAME }}/cadvisor:latest --amend ${{ secrets.DOCKERHUB_USERNAME }}/cadvisor-amd64:latest --amend ${{ secrets.DOCKERHUB_USERNAME }}/cadvisor-arm64:latest
docker manifest create ${{ secrets.DOCKERHUB_USERNAME }}/cadvisor:${{ github.event.inputs.cadvisor_version }} --amend ${{ secrets.DOCKERHUB_USERNAME }}/cadvisor-amd64:${{ github.event.inputs.cadvisor_version }} --amend ${{ secrets.DOCKERHUB_USERNAME }}/cadvisor-arm64:${{ github.event.inputs.cadvisor_version }}
docker manifest create ${{ secrets.DOCKERHUB_USERNAME }}/cadvisor:latest -a ${{ secrets.DOCKERHUB_USERNAME }}/cadvisor:latest-amd64 -a ${{ secrets.DOCKERHUB_USERNAME }}/cadvisor:latest-arm64
docker manifest create ${{ secrets.DOCKERHUB_USERNAME }}/cadvisor:${{ github.event.inputs.cadvisor_version }} -a ${{ secrets.DOCKERHUB_USERNAME }}/cadvisor:${{ github.event.inputs.cadvisor_version }}-amd64 -a ${{ secrets.DOCKERHUB_USERNAME }}/cadvisor:${{ github.event.inputs.cadvisor_version }}-arm64
docker manifest push ${{ secrets.DOCKERHUB_USERNAME }}/cadvisor:latest
docker manifest push ${{ secrets.DOCKERHUB_USERNAME }}/cadvisor:${{ github.event.inputs.cadvisor_version }}

0 comments on commit 5ba35b4

Please sign in to comment.