Skip to content
Snippets Groups Projects
Commit 92a2876a authored by Julian Sparber's avatar Julian Sparber
Browse files

CI: build flat-manager and publish to registry

parent cf31829c
No related branches found
No related tags found
No related merge requests found
# Buildah can't use 'overlay' driver when running inside docker
variables:
STORAGE_DRIVER: vfs
stages:
- build
# Expects ${DOCKERIMAGE} which should be the name+tag of the registry image.
# Expects ${DOCKERFILE} variable which should be the path to the Dockerfile.
.build_template:
stage: build
script:
# For debugging
- echo ${CI_REGISTRY_IMAGE} / ${DOCKERFILE} / ${DOCKERIMAGE}
- dnf install -y buildah podman
- buildah login -u gitlab-ci-token -p ${CI_JOB_TOKEN} ${CI_REGISTRY}
# Newer versions of podman/buildah try to set overlayfs mount options when
# using the vfs driver, and this causes errors.
- sed -i '/^mountopt =.*/d' /etc/containers/storage.conf
- buildah bud --format=docker --pull -f ${DOCKERFILE} -t ${DOCKERIMAGE} .
- buildah push ${DOCKERIMAGE}
after_script:
# don't try to use systemd/journald
- |
cat >> /etc/containers/libpod.conf << END
cgroup_manager = "cgroupfs"
events_logger = "file"
END
- buildah inspect --format "{{.FromImageID}}" ${DOCKERIMAGE}
only:
- main
- triggers
- schedules
retry: 1
build_flat_manager_docker_arm64:
extends: .build_template
image: arm64v8/fedora
tags:
- librem5:arm64
variables:
DOCKERIMAGE: ${CI_REGISTRY_IMAGE}/base
DOCKERFILE: Dockerfile
build_flat_manager_docker:
extends: .build_template
image: fedora:latest
tags:
- librem5
variables:
DOCKERIMAGE: ${CI_REGISTRY_IMAGE}/base
DOCKERFILE: Dockerfile
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment