Skip to content
Snippets Groups Projects
Unverified Commit 65a2598f authored by Varac's avatar Varac
Browse files

Build for aarch64

parent 0d8284af
No related branches found
No related tags found
1 merge request!132Build for aarch64
Pipeline #177539 passed
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
build: build:
stage: build stage: build
# https://quay.io/repository/buildah/stable?tab=tags&tag=latest # https://quay.io/repository/buildah/stable?tab=tags&tag=latest
# Based on Fedora Linux 38 (v1.32.0)
image: quay.io/buildah/stable:v1.32.0 image: quay.io/buildah/stable:v1.32.0
variables: variables:
# Use vfs with buildah. Docker offers overlayfs as a default, but Buildah # Use vfs with buildah. Docker offers overlayfs as a default, but Buildah
...@@ -11,7 +12,6 @@ build: ...@@ -11,7 +12,6 @@ build:
# Newer versions of docker can handle the OCI format, but older versions, like # Newer versions of docker can handle the OCI format, but older versions, like
# the one shipped with Fedora 30, cannot handle the format. # the one shipped with Fedora 30, cannot handle the format.
BUILDAH_FORMAT: docker BUILDAH_FORMAT: docker
FQ_IMAGE_NAME: "$CI_REGISTRY_IMAGE/test"
before_script: before_script:
# GitLab Container Registry credentials taken from the # GitLab Container Registry credentials taken from the
# [predefined CI/CD variables](../variables/index.md#predefined-cicd-variables) # [predefined CI/CD variables](../variables/index.md#predefined-cicd-variables)
...@@ -21,7 +21,7 @@ build: ...@@ -21,7 +21,7 @@ build:
- export version=$(grep 'FROM' Dockerfile|cut -d':' -f2) - export version=$(grep 'FROM' Dockerfile|cut -d':' -f2)
- echo "Building image tag $version" - echo "Building image tag $version"
- buildah images - buildah images
# See https://github.com/containers/buildah/issues/1901#issuecomment-638119049 # https://medium.com/oracledevs/building-multi-architecture-containers-with-buildah-44ed100ec3f3
- buildah build --isolation=chroot -t ${FQ_IMAGE_NAME}:${version} - buildah build --platform linux/arm64/v8 -t ${CI_REGISTRY_IMAGE}:${version}
- buildah images - buildah images
- buildah push ${FQ_IMAGE_NAME}:${version} - buildah push ${CI_REGISTRY_IMAGE}:${version}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment