Skip to content

Commit

Permalink
Update .gitlab-ci.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
alanpeng authored Apr 5, 2021
1 parent 2ad6dcd commit 4382eb0
Showing 1 changed file with 22 additions and 12 deletions.
34 changes: 22 additions & 12 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,22 @@
build_image:
image: docker:git
services:
- docker:dind
before_script:
- docker run --privileged linuxkit/binfmt:v0.8
- docker run -d --privileged -p 1234:1234 --name buildkit moby/buildkit:latest --addr tcp://0.0.0.0:1234 --oci-worker-platform linux/amd64 --oci-worker-platform linux/arm64
- docker cp buildkit:/usr/bin/buildctl /usr/bin/
- export BUILDKIT_HOST=tcp://0.0.0.0:1234
script:
- sh build-images.sh
when: always
stages:
- build

buildkitd:
stage: build

services:
- alias: buildkitd
name: moby/buildkit:rootless
command:
- "--oci-worker-no-process-sandbox"
- "--addr"
- "tcp://0.0.0.0:1234"
variables:
BUILDKIT_HOST: tcp://buildkitd:1234

image:
name: moby/buildkit:rootless
entrypoint: [ "sh", "-c" ]
script:
- sh build-images.sh
when: always

0 comments on commit 4382eb0

Please sign in to comment.