This is an automated email from the ASF dual-hosted git repository. mbalassi pushed a commit to branch release-0.1 in repository https://gitbox.apache.org/repos/asf/flink-kubernetes-operator.git
commit 7cb7d825f1c6f5be24a54b7647b5014610510a44 Author: Marton Balassi <[email protected]> AuthorDate: Mon Mar 28 15:54:25 2022 +0200 [FLINK-26214] Add support for ARM64 docker image --- .github/workflows/docker-bake.hcl | 29 +++++++++++++++++++++++++++++ .github/workflows/docker_push.yml | 14 +++++++++----- 2 files changed, 38 insertions(+), 5 deletions(-) diff --git a/.github/workflows/docker-bake.hcl b/.github/workflows/docker-bake.hcl new file mode 100644 index 0000000..82b2fee --- /dev/null +++ b/.github/workflows/docker-bake.hcl @@ -0,0 +1,29 @@ +################################################################################ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +################################################################################ + +target "docker-metadata-action" {} + +target "bake-platform" { + inherits = ["docker-metadata-action"] + context = "./" + dockerfile = "Dockerfile" + platforms = [ + "linux/amd64", + "linux/arm64/v8", + ] +} diff --git a/.github/workflows/docker_push.yml b/.github/workflows/docker_push.yml index 6f8d2d4..709d247 100644 --- a/.github/workflows/docker_push.yml +++ b/.github/workflows/docker_push.yml @@ -39,6 +39,9 @@ jobs: - name: Check out the repo uses: actions/checkout@v2 + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v1 + - name: Log in to the Container registry uses: docker/login-action@v1 with: @@ -58,10 +61,11 @@ jobs: type=semver,pattern={{version}} type=semver,pattern={{major}}.{{minor}} - - name: Build and push Docker images - uses: docker/build-push-action@v2 + - name: Build and push Docker images (supported platforms) + uses: docker/[email protected] with: - context: . + files: | + .github/workflows/docker-bake.hcl + ${{ steps.meta.outputs.bake-file }} + targets: bake-platform push: ${{ github.event_name != 'pull_request' }} - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }}
