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

chore: setup release to reuse CTF from components workflow #1077

Merged

Conversation

jakobmoellerdev
Copy link
Contributor

What this PR does / why we need it

This makes sure that the CTF is only built once in the release flow (during the components build) and then reused across the release. For this it needs to be built with the correct version during release (e.g. v0.18.0-rc.1) which we now pass via EFFECTIVE_VERSION into the Makefiles in the repo.

This allows us to get rid of the make CTF_TYPE=directory ctf step in the goreleaser configuration so we now no longer need to build the ctf twice.

Which issue(s) this PR fixes

Part of the release candidate transparency rework in #995 as it allows us to prepare the release to only use the binaries from the CTFs.

@jakobmoellerdev jakobmoellerdev requested a review from a team as a code owner November 12, 2024 14:54
@github-actions github-actions bot added the chore label Nov 12, 2024
@jakobmoellerdev
Copy link
Contributor Author

@jakobmoellerdev jakobmoellerdev force-pushed the chore/use-ctf-for-release branch from bb5ba44 to 233a973 Compare November 12, 2024 17:08
@jakobmoellerdev jakobmoellerdev marked this pull request as draft November 12, 2024 18:40
@jakobmoellerdev jakobmoellerdev force-pushed the chore/use-ctf-for-release branch 2 times, most recently from 818c362 to 49a7e00 Compare November 13, 2024 09:41
@jakobmoellerdev jakobmoellerdev marked this pull request as ready for review November 13, 2024 10:15
@jakobmoellerdev
Copy link
Contributor Author

Had to change up the original PR because in PRs we do not set EFFECTIVE_VERSION but have an empty string but the makefiles didnt recognize that.

@hilmarf hilmarf added this to the 2024-Q4 milestone Nov 13, 2024
Makefile Outdated Show resolved Hide resolved
Makefile Outdated Show resolved Hide resolved
Makefile Outdated Show resolved Hide resolved
hilmarf
hilmarf previously approved these changes Nov 15, 2024
Makefile Outdated Show resolved Hide resolved
examples/make/Makefile Outdated Show resolved Hide resolved
hilmarf
hilmarf previously approved these changes Nov 20, 2024
Co-authored-by: Hilmar Falkenberg <hilmar.falkenberg@sap.com>
@github-actions github-actions bot added the component/github-actions Changes on GitHub Actions or within `.github/` directory label Nov 21, 2024
@hilmarf hilmarf enabled auto-merge (squash) November 21, 2024 10:53
@hilmarf hilmarf merged commit ecd46ec into open-component-model:main Nov 21, 2024
19 checks passed
jakobmoellerdev added a commit that referenced this pull request Nov 22, 2024
<!-- markdownlint-disable MD041 -->
#### What this PR does / why we need it

Makes sure that release notes are correctly drawn in and that we always
have the version set correctly in our CTFs.

#### Which issue(s) this PR fixes
<!--
Usage: `Fixes #<issue number>`, or `Fixes (paste link of issue)`.
-->

This fixes up the release action in 2 important ways:

1. As part of the removal of the release notes we now no longer have a
file to use for release notes to give to goreleaser. This means we have
to temporarily create one
2. While discovering this I noticed that the Component Versions that are
built, are actually using the `VERSION` variable while
`EFFECTIVE_VERSION` is a combination of VERSION+COMMIT by default. I
didnt want to change this behavior originally, so now I started to use
VERSION for the Makefiles (which also means I had to export them as
settable). This now leads to correct CTF versions `v0.19.0-rc.1` instead
of `v0.19.0-dev` for example.

As such its a follow up from
#1120 and
#1077
@hilmarf hilmarf added the kind/chore chore, maintenance, etc. label Nov 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/github-actions Changes on GitHub Actions or within `.github/` directory kind/chore chore, maintenance, etc. size/m Medium
Projects
Status: 🔒Closed
Development

Successfully merging this pull request may close these issues.

2 participants