Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
70 changes: 33 additions & 37 deletions .drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6750,7 +6750,7 @@ volumes:
################################################
# Generated using dronegen, do not edit by hand!
# Use 'make dronegen' to update.
# Generated at dronegen/os_repos.go:250
# Generated at dronegen/os_repos.go:253
################################################

kind: pipeline
Expand Down Expand Up @@ -6778,7 +6778,7 @@ steps:
################################################
# Generated using dronegen, do not edit by hand!
# Use 'make dronegen' to update.
# Generated at dronegen/os_repos.go:274
# Generated at dronegen/os_repos.go:277
################################################

kind: pipeline
Expand Down Expand Up @@ -6812,16 +6812,6 @@ steps:
- git init && git remote add origin ${DRONE_REMOTE_URL}
- git fetch origin --tags
- git checkout -qf "${DRONE_TAG}"
depends_on:
- Verify build is tagged
- name: Check if tag is prerelease
image: golang:1.18-alpine
commands:
- cd "/go/src/github.com/gravitational/teleport/build.assets/tooling"
- go run ./cmd/check -tag ${DRONE_TAG} -check prerelease || (echo '---> This is
a prerelease, not continuing promotion for ${DRONE_TAG}' && exit 78)
depends_on:
- Check out code
- name: Assume Download AWS Role
image: amazon/aws-cli
commands:
Expand Down Expand Up @@ -6849,12 +6839,11 @@ steps:
depends_on:
- Verify build is tagged
- Check out code
- Check if tag is prerelease
- name: Download artifacts for "${DRONE_TAG}"
image: amazon/aws-cli
commands:
- mkdir -pv "$ARTIFACT_PATH"
- rm -rf "$ARTIFACT_PATH/*"
- rm -rf "$ARTIFACT_PATH"/*
- aws s3 sync --no-progress --delete --exclude "*" --include "*.deb*" s3://$AWS_S3_BUCKET/teleport/tag/${DRONE_TAG##v}/
"$ARTIFACT_PATH"
environment:
Expand All @@ -6865,9 +6854,9 @@ steps:
- name: awsconfig
path: /root/.aws
depends_on:
- Assume Download AWS Role
- Verify build is tagged
- Check out code
- Check if tag is prerelease
- name: Assume Upload AWS Role
image: amazon/aws-cli
commands:
Expand All @@ -6893,9 +6882,19 @@ steps:
- name: awsconfig
path: /root/.aws
depends_on:
- Download artifacts for "${DRONE_TAG}"
- Verify build is tagged
- Check out code
- name: Check if tag is prerelease
image: golang:1.18-alpine
commands:
- cd "/go/src/github.com/gravitational/teleport/build.assets/tooling"
- go run ./cmd/check -tag ${DRONE_TAG} -check prerelease || (echo '---> This is
a prerelease, not continuing promotion for ${DRONE_TAG}' && exit 78)
depends_on:
- Assume Upload AWS Role
- Verify build is tagged
- Check out code
- Check if tag is prerelease
- name: Publish debs to APT repos for "${DRONE_TAG}"
image: golang:1.18.4-bullseye
commands:
Expand Down Expand Up @@ -6929,10 +6928,9 @@ steps:
- name: awsconfig
path: /root/.aws
depends_on:
- Download artifacts for "${DRONE_TAG}"
- Check if tag is prerelease
- Verify build is tagged
- Check out code
- Check if tag is prerelease
volumes:
- name: apt-persistence
claim:
Expand All @@ -6947,7 +6945,7 @@ volumes:
################################################
# Generated using dronegen, do not edit by hand!
# Use 'make dronegen' to update.
# Generated at dronegen/os_repos.go:250
# Generated at dronegen/os_repos.go:253
################################################

kind: pipeline
Expand Down Expand Up @@ -6975,7 +6973,7 @@ steps:
################################################
# Generated using dronegen, do not edit by hand!
# Use 'make dronegen' to update.
# Generated at dronegen/os_repos.go:274
# Generated at dronegen/os_repos.go:277
################################################

kind: pipeline
Expand Down Expand Up @@ -7009,16 +7007,6 @@ steps:
- git init && git remote add origin ${DRONE_REMOTE_URL}
- git fetch origin --tags
- git checkout -qf "${DRONE_TAG}"
depends_on:
- Verify build is tagged
- name: Check if tag is prerelease
image: golang:1.18-alpine
commands:
- cd "/go/src/github.com/gravitational/teleport/build.assets/tooling"
- go run ./cmd/check -tag ${DRONE_TAG} -check prerelease || (echo '---> This is
a prerelease, not continuing promotion for ${DRONE_TAG}' && exit 78)
depends_on:
- Check out code
- name: Assume Download AWS Role
image: amazon/aws-cli
commands:
Expand Down Expand Up @@ -7046,12 +7034,11 @@ steps:
depends_on:
- Verify build is tagged
- Check out code
- Check if tag is prerelease
- name: Download artifacts for "${DRONE_TAG}"
image: amazon/aws-cli
commands:
- mkdir -pv "$ARTIFACT_PATH"
- rm -rf "$ARTIFACT_PATH/*"
- rm -rf "$ARTIFACT_PATH"/*
- aws s3 sync --no-progress --delete --exclude "*" --include "*.rpm*" s3://$AWS_S3_BUCKET/teleport/tag/${DRONE_TAG##v}/
"$ARTIFACT_PATH"
environment:
Expand All @@ -7062,9 +7049,9 @@ steps:
- name: awsconfig
path: /root/.aws
depends_on:
- Assume Download AWS Role
- Verify build is tagged
- Check out code
- Check if tag is prerelease
- name: Assume Upload AWS Role
image: amazon/aws-cli
commands:
Expand All @@ -7090,9 +7077,19 @@ steps:
- name: awsconfig
path: /root/.aws
depends_on:
- Download artifacts for "${DRONE_TAG}"
- Verify build is tagged
- Check out code
- name: Check if tag is prerelease
image: golang:1.18-alpine
commands:
- cd "/go/src/github.com/gravitational/teleport/build.assets/tooling"
- go run ./cmd/check -tag ${DRONE_TAG} -check prerelease || (echo '---> This is
a prerelease, not continuing promotion for ${DRONE_TAG}' && exit 78)
depends_on:
- Assume Upload AWS Role
- Verify build is tagged
- Check out code
- Check if tag is prerelease
- name: Publish rpms to YUM repos for "${DRONE_TAG}"
image: golang:1.18.4-bullseye
commands:
Expand Down Expand Up @@ -7127,10 +7124,9 @@ steps:
- name: awsconfig
path: /root/.aws
depends_on:
- Download artifacts for "${DRONE_TAG}"
- Check if tag is prerelease
- Verify build is tagged
- Check out code
- Check if tag is prerelease
volumes:
- name: yum-persistence
claim:
Expand Down Expand Up @@ -8007,6 +8003,6 @@ volumes:
temp: {}
---
kind: signature
hmac: 0d3063844a5f8bf25043a691517ab358dc32739e233b593267f1a0fec96351c5
hmac: 9063bb609685ab20fc323ed494bab70ed5ea49593cf84458c14cc94afcacceec

...
13 changes: 0 additions & 13 deletions dronegen/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -232,19 +232,6 @@ func waitForDockerStep() step {
}
}

func verifyValidPromoteRunSteps(checkoutPath, commit string, isParallelismEnabled bool) []step {
tagStep := verifyTaggedStep()
cloneStep := cloneRepoStep(checkoutPath, commit)
verifyStep := verifyNotPrereleaseStep(checkoutPath)

if isParallelismEnabled {
cloneStep.DependsOn = []string{tagStep.Name}
verifyStep.DependsOn = []string{cloneStep.Name}
}

return []step{tagStep, cloneStep, verifyStep}
}

func verifyTaggedStep() step {
return step{
Name: "Verify build is tagged",
Expand Down
Loading