diff --git a/.github/workflows/build_and_test.yml b/.github/workflows/build_and_test.yml index d037cbcc..2fc8a904 100644 --- a/.github/workflows/build_and_test.yml +++ b/.github/workflows/build_and_test.yml @@ -117,6 +117,8 @@ jobs: uses: docker/bake-action@a4d7f0b5b91c14a296d792d4ec53a9db17f02e67 # v5.5.0 with: push: true + set: TARGET_ARCH=[linux/amd64,linux/arm64] + - name: Show all built images run: docker images diff --git a/docker-bake.hcl b/docker-bake.hcl index 98138f3b..9959aa17 100644 --- a/docker-bake.hcl +++ b/docker-bake.hcl @@ -103,7 +103,7 @@ variable "ALFRESCO_REPO_USER_NAME" { } variable "TARGET_ARCH" { - default = "" # linux/amd64 linux/arm64 + default = [] # e.g. ["linux/amd64"] } target "java_base" { @@ -139,7 +139,7 @@ target "java_base" { } tags = ["${REGISTRY}/${REGISTRY_NAMESPACE}/alfresco-base-java:${JDIST}${JAVA_MAJOR}-${DISTRIB_NAME}${DISTRIB_MAJOR}"] output = ["type=cacheonly"] - platforms = TARGET_ARCH != "" ? ["${TARGET_ARCH}"] : [] + platforms = TARGET_ARCH != "" ? TARGET_ARCH : [] } variable "TOMCAT_MAJOR" { @@ -183,7 +183,7 @@ target "tomcat_base" { } tags = ["${REGISTRY}/${REGISTRY_NAMESPACE}/alfresco-base-tomcat:tomcat${TOMCAT_MAJOR}-${JDIST}${JAVA_MAJOR}-${DISTRIB_NAME}${DISTRIB_MAJOR}"] output = ["type=cacheonly"] - platforms = TARGET_ARCH != "" ? ["${TARGET_ARCH}"] : [] + platforms = TARGET_ARCH != "" ? TARGET_ARCH : [] } target "repository" {