Skip to content

[github] Workflow to automatically build and push etcd binaries#4

Merged
aneesh1 merged 21 commits intorelease-3.5-dd-v3.5.14-dd.1from
aa/github-workflow-dd-build
Sep 23, 2024
Merged

[github] Workflow to automatically build and push etcd binaries#4
aneesh1 merged 21 commits intorelease-3.5-dd-v3.5.14-dd.1from
aa/github-workflow-dd-build

Conversation

@aneesh1
Copy link

@aneesh1 aneesh1 commented Sep 19, 2024

Automates building and pushing etcd binaries whenever we create a new branch.

@aneesh1 aneesh1 force-pushed the aa/github-workflow-dd-build branch from 69ae67e to e5253e0 Compare September 19, 2024 18:51
@aneesh1 aneesh1 force-pushed the aa/github-workflow-dd-build branch from e5253e0 to 93f0ec1 Compare September 19, 2024 18:54
@aneesh1 aneesh1 force-pushed the aa/github-workflow-dd-build branch from c961f09 to e6112fc Compare September 19, 2024 19:18
@aneesh1 aneesh1 force-pushed the aa/github-workflow-dd-build branch 2 times, most recently from 0719df3 to c0ed647 Compare September 19, 2024 21:51
@aneesh1 aneesh1 force-pushed the aa/github-workflow-dd-build branch from c0ed647 to 2683d78 Compare September 19, 2024 22:00
@aneesh1 aneesh1 force-pushed the aa/github-workflow-dd-build branch from 57468ea to cecefea Compare September 20, 2024 04:18
@aneesh1 aneesh1 force-pushed the aa/github-workflow-dd-build branch from 7e49861 to a97f6bc Compare September 20, 2024 13:40
@aneesh1 aneesh1 force-pushed the aa/github-workflow-dd-build branch from a9e2f69 to dc4eff0 Compare September 20, 2024 13:51
@aneesh1 aneesh1 force-pushed the aa/github-workflow-dd-build branch from e787af6 to a3bd987 Compare September 20, 2024 16:28
env:
KUBE_BUILD_PLATFORM: ${{ matrix.platform }}
- name: Build etcd
run: REPOSITORY=https://github.com/${{ env.GITHUB_REPOSITORY}}.git ./scripts/build-binary ${{ env.RELEASE_VERSION }}
Copy link
Author

Choose a reason for hiding this comment

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

There was another script, ./scripts/release.sh, that I tried to use - it didn't work.

If I supplied a custom tag like RELEASE_VERSION=v3.5.14-dd.16-aneesh-test, it still would look for a branch name like release-3.5. We seem to have a different branch naming scheme and I didn't want to change the code in ./scripts/release.sh, so I found this script instead which builds the binaries for us.

If we're interested in changing our branch naming scheme, we can switch to ./scripts/release.sh in a follow up PR, but for now, this works.

asset_path: ./_output/release-tars/etcd-${{ env.RELEASE_VERSION }}-${{ matrix.platform }}.${{ matrix.extension }}
asset_name: etcd-${{ env.RELEASE_VERSION }}-${{ matrix.platform }}.${{ matrix.extension }}
asset_content_type: application/tar+gzip
addchecksum:
Copy link
Author

Choose a reason for hiding this comment

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

Needed to be separate b/c it relies on the output of the release job and b/c it can't run with strategy.matrix since it'll try and upload a file twice (which doesn't work).

Copy link

Choose a reason for hiding this comment

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

Why not merge both.
Also do we need the checksum file at all ?
Or do we need the checksum file to be named SHA256SUMS ?

Copy link
Author

@aneesh1 aneesh1 Sep 23, 2024

Choose a reason for hiding this comment

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

Also do we need the checksum file at all ?

We use it on our ansible playbook (specifically, this function) - I think it'd be good to keep.

I've changed the flow to now be:

  1. Build everything
  2. Define the build matrix to attach select artifacts to the release.

@aneesh1 aneesh1 marked this pull request as ready for review September 20, 2024 18:17
@aneesh1 aneesh1 force-pushed the aa/github-workflow-dd-build branch from dee982f to e7d44a6 Compare September 23, 2024 18:47
Copy link

@nyodas nyodas left a comment

Choose a reason for hiding this comment

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

Let's try this out and see if we're good.

@aneesh1 aneesh1 merged commit 44e611b into release-3.5-dd-v3.5.14-dd.1 Sep 23, 2024
@badouralix badouralix deleted the aa/github-workflow-dd-build branch November 24, 2025 16:43
badouralix pushed a commit that referenced this pull request Feb 4, 2026
Signed-off-by: Ayaz Badouraly <ayaz.badouraly@datadoghq.com>
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.

2 participants