mirror of
https://gitlab.com/Bockiii/deemix-docker.git
synced 2024-08-30 17:32:18 +00:00
31 lines
1.1 KiB
YAML
31 lines
1.1 KiB
YAML
image: docker:latest
|
|
services:
|
|
- docker:dind
|
|
|
|
stages:
|
|
- build
|
|
|
|
variables:
|
|
IMAGE: registry.gitlab.com/bockiii/deemix-docker
|
|
DOCKER_CLI_EXPERIMENTAL: enabled
|
|
|
|
before_script:
|
|
- docker login -u gitlab-ci-token -p $CI_JOB_TOKEN $CI_REGISTRY
|
|
|
|
build:
|
|
stage: build
|
|
script:
|
|
- docker run --rm --privileged multiarch/qemu-user-static:register --reset
|
|
- docker build --pull -f Dockerfile.arm64v8 -t $IMAGE:arm64v8 .
|
|
- docker push $IMAGE:arm64v8
|
|
- docker build --pull -f Dockerfile.arm32v7 -t $IMAGE:arm32v7 .
|
|
- docker push $IMAGE:arm32v7
|
|
- docker build --pull -t $IMAGE:amd64 .
|
|
- docker push $IMAGE:amd64
|
|
- set -e
|
|
- HOST_ARCH=$(uname -m)
|
|
- HOST_ARCH_ALIAS=$([[ "${HOST_ARCH}" == "x86_64" ]] && echo "amd64" || echo "${HOST_ARCH}")
|
|
- MANIFEST_TOOL_VERSION=$(curl -s https://api.github.com/repos/estesp/manifest-tool/releases/latest | grep 'tag_name' | cut -d\" -f4)
|
|
- curl -L https://github.com/estesp/manifest-tool/releases/download/$MANIFEST_TOOL_VERSION/manifest-tool-linux-$HOST_ARCH_ALIAS -o manifest-tool
|
|
- chmod +x manifest-tool
|
|
- ./manifest-tool push from-spec manifest.yaml |