Skip to content

Commit

Permalink
[CI] Migrate to k8s-based CI runners
Browse files Browse the repository at this point in the history
  • Loading branch information
mborst committed Feb 14, 2024
1 parent 6447050 commit 4950413
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,12 @@ build-staging:
image: $DOCKER_IMAGE
rules:
- if: '$CI_COMMIT_REF_NAME != "master"'
tags: ["runner:docker"]
tags:
- "arch:amd64"
script:
- docker build -t registry.ddbuild.io/kafka-kit:${CI_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA} --label target=staging --target dd-image -f Dockerfile .
- docker push registry.ddbuild.io/kafka-kit:${CI_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}
- ddsign sign registry.ddbuild.io/kafka-kit:${CI_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA} --digest-from-docker
- METADATA_FILE=$(mktemp)
- docker buildx build -t registry.ddbuild.io/kafka-kit:${CI_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA} --label target=staging --target dd-image -f Dockerfile --push --metadata-file ${METADATA_FILE} .
- ddsign sign registry.ddbuild.io/kafka-kit:${CI_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA} --docker-metadata-file ${METADATA_FILE}


build-prod:
Expand All @@ -22,8 +23,9 @@ build-prod:
image: $DOCKER_IMAGE
rules:
- if: '$CI_COMMIT_REF_NAME == "master"'
tags: ["runner:docker"]
tags:
- "arch:amd64"
script:
- docker build -t registry.ddbuild.io/kafka-kit:${CI_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA} --label target=prod --target dd-image -f Dockerfile .
- docker push registry.ddbuild.io/kafka-kit:${CI_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA}
- ddsign sign registry.ddbuild.io/kafka-kit:${CI_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA} --digest-from-docker
- METADATA_FILE=$(mktemp)
- docker buildx build -t registry.ddbuild.io/kafka-kit:${CI_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA} --label target=prod --target dd-image -f Dockerfile --push --metadata-file ${METADATA_FILE} .
- ddsign sign registry.ddbuild.io/kafka-kit:${CI_PIPELINE_ID}-${CI_COMMIT_SHORT_SHA} --docker-metadata-file ${METADATA_FILE}

0 comments on commit 4950413

Please sign in to comment.