Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Setup the Release pipeline #740

Merged
merged 5 commits into from
Nov 22, 2023
Merged

Setup the Release pipeline #740

merged 5 commits into from
Nov 22, 2023

Conversation

nkammah
Copy link
Contributor

@nkammah nkammah commented Nov 21, 2023

Description

Migrate the Jenkins Release pipeline to Buildkite.

Notes:

  • I moved all the logic to load the GPG keys into the pre-command hook to benefit from secrets redaction features and move away from the file based approach used in the .ci/Makefile
  • With the above point, I had to rename an env. variable to GPG_FINGERPRINT_SECRET instead of GPG_FINGERPRINT so that Buildkite would always redact it and we don't risk leaking it (with a set -x or printenv). I don't think it would affect anyone since this is used only in the CI flow.
  • The k8s agent used for the build is rather big (`cpu: "8" memory:"32G") but it seems needed as go-releaser is very hungry on cross-compiling all the targets in parallel - I had to iterate quite a bit to get to that combo.
  • Related to the above, I re-ordered the goarch options to put amd64 at the end which helped with getting the build to succeed as opposed to getting to resource exhaustion - i'm not too sure why.
  • The .ci/Makefile should still work to run the flow as a developer instead of ci.

Related Issues

Motivation and Context

How Has This Been Tested?

Types of Changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Refactoring (improves code quality but has no user-facing effect)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation

Readiness Checklist

  • My code follows the code style of this project
  • My change requires a change to the documentation
  • I have updated the documentation accordingly
  • I have added tests to cover my changes
  • All new and existing tests passed

For now use the release-nopublish target
@nkammah nkammah requested a review from a team as a code owner November 21, 2023 09:38
@nkammah nkammah requested review from tobio and dimuon November 21, 2023 09:38
Copy link
Contributor

@dimuon dimuon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@nkammah nkammah mentioned this pull request Nov 21, 2023
10 tasks
command: .buildkite/release.sh
agents:
image: "docker.io/library/golang:1.21"
cpu: "8" # The release flow needs that many or hits https://github.com/goreleaser/goreleaser/issues/304
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this the right issue number? Add config for number of parallel builds #304?

@nkammah nkammah force-pushed the buildkite-release-pipeline branch from 3d05307 to 61b49fd Compare November 21, 2023 15:26
@nkammah nkammah merged commit 475ba5f into master Nov 22, 2023
@nkammah nkammah deleted the buildkite-release-pipeline branch November 22, 2023 08:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants