|
| 1 | +# This file is managed by ServiceBot plugin - Semaphore. The content in this file is created using a common |
| 2 | +# template and configurations in service.yml. |
| 3 | +# Any modifications made to ths file will be overwritten by the generated content in nightly runs. |
| 4 | +# For more information, please refer to the page: |
| 5 | +# https://confluentinc.atlassian.net/wiki/spaces/Foundations/pages/2871296194/Add+SemaphoreCI |
| 6 | +version: v1.0 |
| 7 | +name: build-test-release |
| 8 | +agent: |
| 9 | + machine: |
| 10 | + type: s1-prod-ubuntu20-04-amd64-1 |
| 11 | + |
| 12 | +fail_fast: |
| 13 | + cancel: |
| 14 | + when: "true" |
| 15 | + |
| 16 | +execution_time_limit: |
| 17 | + hours: 1 |
| 18 | + |
| 19 | +queue: |
| 20 | + - when: "branch != 'master' and branch !~ '[0-9]+\\.[0-9]+\\.[0-9]+'" |
| 21 | + processing: parallel |
| 22 | + |
| 23 | +global_job_config: |
| 24 | + prologue: |
| 25 | + commands: |
| 26 | + - checkout |
| 27 | + - . vault-setup |
| 28 | + # Semaphore does not accept empty values for parameters. |
| 29 | + - if [[ -z "$CONFLUENT_VERSION" ]]; then echo "Must specify CONFLUENT_VERSION" && exit 1; fi |
| 30 | + - if [[ -z "$IMAGE_REVISION" ]]; then echo "Must specify IMAGE_REVISION" && exit 1; fi |
| 31 | + - if [[ -z "$PROMOTE_OS_TYPE" ]]; then echo "Must specify PROMOTE_OS_TYPE" && exit 1; fi |
| 32 | + - >- |
| 33 | + echo """ |
| 34 | + Parameters: |
| 35 | + ========================== |
| 36 | + CONFLUENT_VERSION: $CONFLUENT_VERSION |
| 37 | + IMAGE_REVISION: $IMAGE_REVISION |
| 38 | + UPDATE_LATEST_TAG: $UPDATE_LATEST_TAG |
| 39 | + PACKAGING_BUILD_NUMBER: $PACKAGING_BUILD_NUMBER |
| 40 | + PROMOTE_OS_TYPE: $PROMOTE_OS_TYPE |
| 41 | + """ |
| 42 | + - export BRANCH_TAG=$(echo $SEMAPHORE_GIT_BRANCH | tr / -) |
| 43 | + - export DOCKER_PROD_REGISTRY="519856050701.dkr.ecr.us-west-2.amazonaws.com/docker/prod/" |
| 44 | + - export PROMOTED_TAG_PREFIX="$CONFLUENT_VERSION-$IMAGE_REVISION" |
| 45 | + - if [[ ! "$PACKAGING_BUILD_NUMBER" ]]; then export $PACKAGING_BUILD_NUMBER="latest"; fi |
| 46 | + - docker login --username $DOCKERHUB_USER --password $DOCKERHUB_APIKEY |
| 47 | + - export AMD_ARCH=.amd64 |
| 48 | + |
| 49 | +blocks: |
| 50 | + - name: Promote AMD |
| 51 | + dependencies: [] |
| 52 | + task: |
| 53 | + jobs: |
| 54 | + - name: Create Manifest |
| 55 | + dependencies: ["Promote AMD"] |
| 56 | + task: |
| 57 | + jobs: |
0 commit comments