2020-06-05 20:49:21 +00:00
|
|
|
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
|
|
|
|
|
2020-06-05 21:45:21 +00:00
|
|
|
build:
|
2020-06-05 21:23:47 +00:00
|
|
|
stage: build
|
2020-06-05 20:49:21 +00:00
|
|
|
script:
|
2020-06-05 21:45:21 +00:00
|
|
|
- docker run --rm --privileged multiarch/qemu-user-static:register --reset
|
2020-06-05 21:57:53 +00:00
|
|
|
- docker build --pull -f Dockerfile.arm64v8 -t $IMAGE:arm64v8 .
|
2020-06-05 21:45:21 +00:00
|
|
|
- docker push $IMAGE:arm64v8
|
2020-06-05 22:18:32 +00:00
|
|
|
- docker build --pull -f Dockerfile.arm32v7 -t $IMAGE:arm32v7 .
|
|
|
|
- docker push $IMAGE:arm32v7
|
2020-06-05 21:45:21 +00:00
|
|
|
- docker build --pull -t $IMAGE:amd64 .
|
2020-06-05 21:23:47 +00:00
|
|
|
- docker push $IMAGE:amd64
|
2020-06-05 22:29:32 +00:00
|
|
|
- set -e
|
|
|
|
- HOST_ARCH=$(uname -m)
|
|
|
|
- HOST_ARCH_ALIAS=$([[ "${HOST_ARCH}" == "x86_64" ]] && echo "amd64" || echo "${HOST_ARCH}")
|
2020-06-05 22:38:36 +00:00
|
|
|
- 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
|