Skip to content

Commit

Permalink
build multiplatform docker image
Browse files Browse the repository at this point in the history
  • Loading branch information
gabriel-v committed Sep 26, 2023
1 parent d9f4134 commit 7f4ef29
Showing 1 changed file with 52 additions and 3 deletions.
55 changes: 52 additions & 3 deletions .drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ steps:
image: plugins/docker
settings:
repo: liquidinvestigations/hoover-snoop2
tags: 0-base-x86
tags: 0-base
dockerfile: Dockerfile.base
username:
from_secret: docker_username
Expand Down Expand Up @@ -221,16 +221,65 @@ steps:

---
# #########################################################
# test
# build multiplatform
# #########################################################

kind: pipeline
name: test
name: build multiplatform

depends_on:
- build x86
- build arm64

clone:
disable: true


steps:
- name: docker multiplatform branch
image: docker
pull: if-not-exists
environment:
IMG: "liquidinvestigations/hoover-snoop2:${DRONE_COMMIT_BRANCH}"
DOCKER_USERNAME:
from_secret: docker_username
DOCKER_PASSWORD:
from_secret: docker_password
commands:
- "docker login -u $DOCKER_USERNAME -p $DOCKER_PASSWORD"
- "docker buildx imagetools create --append $IMG --append $IMG-arm64 --tag $IMG"
when:
event:
- push
- cron

- name: docker multiplatform tag
image: docker
pull: if-not-exists
environment:
IMG: "liquidinvestigations/hoover-snoop2:${DRONE_TAG:1}"
DOCKER_USERNAME:
from_secret: docker_username
DOCKER_PASSWORD:
from_secret: docker_password
commands:
- "docker login -u $DOCKER_USERNAME -p $DOCKER_PASSWORD"
- "docker buildx imagetools create --append $IMG --append $IMG-arm64 --tag $IMG"
when:
event:
- tag
---

# #########################################################
# test
# #########################################################

kind: pipeline
name: test

depends_on:
- build multiplatform

concurrency:
limit: 1

Expand Down

0 comments on commit 7f4ef29

Please sign in to comment.