Upgrade awscli v1 to 1.29.44, v2 to 2.13.17 #53
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions | |
name: v2 | |
on: | |
push: | |
tags: | |
- "2.*" | |
jobs: | |
build: | |
name: Build | |
runs-on: ubuntu-latest | |
env: | |
BUILD_CTX: v2 | |
BUILD_PLATFORMS: linux/amd64,linux/arm64 | |
DOCKER_VERSION: "24.0.5" | |
DOCKER_BUILDX_VERSION: "0.11.2" | |
DOCKER_COMPOSE_VERSION: "2.20.2" | |
steps: | |
- name: Setup Envs | |
run: echo BUILD_TAG=${GITHUB_REF#refs/tags/} >> $GITHUB_ENV | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Docker Metadata | |
id: meta | |
uses: docker/metadata-action@v4 | |
# https://github.com/docker/metadata-action | |
with: | |
images: | | |
ghcr.io/cheyilin/docker-awscli | |
cheyilin/docker-awscli | |
tags: | | |
type=raw,value=${{ env.BUILD_CTX }} | |
type=semver,pattern={{version}} | |
flavor: | | |
latest=true | |
- name: Setup QEMU | |
uses: docker/setup-qemu-action@v2 | |
with: | |
platforms: ${{ env.BUILD_PLATFORMS }} | |
- name: Setup Docker Buildx | |
uses: docker/setup-buildx-action@v2 | |
- name: Login to GHCR | |
uses: docker/login-action@v2 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Login to DockerHub | |
uses: docker/login-action@v2 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: Build and Push | |
uses: docker/build-push-action@v4 | |
# https://github.com/docker/build-push-action | |
with: | |
context: ${{ env.BUILD_CTX }} | |
platforms: ${{ env.BUILD_PLATFORMS }} | |
build-args: | | |
DOCKER_VERSION=${{ env.DOCKER_VERSION }} | |
DOCKER_BUILDX_VERSION=${{ env.DOCKER_BUILDX_VERSION }} | |
DOCKER_COMPOSE_VERSION=${{ env.DOCKER_COMPOSE_VERSION }} | |
AWS_CLI_VERSION=${{ env.BUILD_TAG }} | |
push: true | |
cache-from: type=registry,ref=ghcr.io/cheyilin/docker-awscli:${{ env.BUILD_CTX }} | |
cache-to: type=inline | |
labels: ${{ steps.meta.outputs.labels }} | |
tags: | | |
${{ steps.meta.outputs.tags }} | |
- name: Create Release | |
uses: ncipollo/release-action@v1 | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
body: | | |
## GitHub Container Registry | |
https://ghcr.io/cheyilin/docker-awscli | |
```text | |
ghcr.io/cheyilin/docker-awscli:${{ env.BUILD_TAG }} | |
``` | |
## Docker Hub | |
https://hub.docker.com/r/cheyilin/docker-awscli | |
```text | |
cheyilin/docker-awscli:${{ env.BUILD_TAG }} | |
``` |