chore: Enhance cli release workflow#1755
Conversation
e5ee22f to
d573e21
Compare
d573e21 to
b783d94
Compare
|
Make sure to run these from time to time because: |
57fa398 to
ec58bc3
Compare
I would - do it in this PR that we can review it as well :) |
b58cbb0 to
40b8488
Compare
|
So, I'm not sure how this is working, but there are several errors in the Javascripts... For example, once again, if I'm trying to run the test I'm getting import errors because certain things aren't exported:
I took a look at the attestation, I think we have a problem I didn't think about. The Attestation you download then upload if I understand correctly. This means you download it from the RC and the attestation will contain things like v2.0.0-rc which will be confusing for any consumer. Could you check that please to make sure the attestation is actually for the latest release and not the RC? |
|
Here are some more things we'll discuss:
Actually, verify-attestations.js imports from ./attestation-utils.js but the test file imports parsePatterns, findAssets, and sha256File from ./verify-attestations.js which doesn't re-export them. Probably that's why the test is broken? Not sure what's going on there. :D And that's about it. |
|
@Skarlso, thx for the feedback! I'll look into all of it. Also discussed with @jakobmoellerdev about soley relying on GH's attestation endpoint and API, so I will remove all attestation download, persist as asset, use that for verify. Will also check where to merge existing scripts. One thing I need to add is a gate after the RC, so that promote needs a 4-eyes-principle. |
dca554f to
aa87f18
Compare
Skarlso
left a comment
There was a problem hiding this comment.
Overall, I think this is now pretty okay.
On-behalf-of: Gerald Morrison (SAP) <gerald.morrison@sap.com> Signed-off-by: Gerald Morrison (SAP) <gerald.morrison@sap.com>
On-behalf-of: Gerald Morrison (SAP) <gerald.morrison@sap.com> Signed-off-by: Gerald Morrison (SAP) <gerald.morrison@sap.com>
Skarlso
left a comment
There was a problem hiding this comment.
Let's try this out then. :)
…nor releases. Keep v0.X in examples. On-behalf-of: Gerald Morrison (SAP) <gerald.morrison@sap.com> Signed-off-by: Gerald Morrison (SAP) <gerald.morrison@sap.com>
Co-authored-by: Frederic Wilhelm <fre.wilhelm@gmail.com> Signed-off-by: Gerald Morrison <67469729+morri-son@users.noreply.github.com>
Co-authored-by: Frederic Wilhelm <fre.wilhelm@gmail.com> Signed-off-by: Gerald Morrison <67469729+morri-son@users.noreply.github.com>
…nent-model into enhance-cli-release On-behalf-of: Gerald Morrison (SAP) <gerald.morrison@sap.com> Signed-off-by: Gerald Morrison (SAP) <gerald.morrison@sap.com>
On-behalf-of: Gerald Morrison (SAP) <gerald.morrison@sap.com> Signed-off-by: Gerald Morrison (SAP) <gerald.morrison@sap.com>
On-behalf-of: Gerald Morrison (SAP) <gerald.morrison@sap.com> Signed-off-by: Gerald Morrison (SAP) <gerald.morrison@sap.com>
frewilhelm
left a comment
There was a problem hiding this comment.
Let's get this merged :)
On-behalf-of: Gerald Morrison (SAP) <gerald.morrison@sap.com> <!-- markdownlint-disable MD041 --> #### What this PR does / why we need it This PR improves the existing workflow that builds, tests and publishes the OCM controller and introduces a new workflow that creates releases for the controller. **build workflow:** - add on workflow_call trigger to be able to call from release workflow - remove duplicate build in different steps and replace with buidling just one multi-arch image and extract and reformat single-arch image for later use in e2e (`kind load`). Since ORAS cannot handle the correct format, skopeo is used for exactly that purpose. All other steps keep using ORAS. - Attestate all published artifacts - add floating tag "main" on push to main - Pushes to branches `releases/v*' don't publish images/charts, but only do E2E tests - Trigger "workflow_dispatch" that allows to publish/charts if OCI tests are required **release workflow:** - Align with release workflow for cli as much as possible (#1755) - Call build workflow (build, e2e) - build and publish docker image only once and promote from RC to final release - Repackage and re-attest Helm Chart for Final release - add floating tags - "latest" for highest release (including pre-releases) - "stable" for highest final release <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Introduced a two-phase release process (Release Candidate and Final Release) with automated tag management, artifact promotion, and provenance attestation. * Added OCI image digest support to Helm charts for enhanced image reference flexibility. * Implemented automated changelog generation and release notes publishing. * **Chores** * Updated default controller image versions from "latest" to "0.0.0-main". * Expanded build and release workflows with multi-stage architecture including build, testing, publishing, and conformance stages. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Signed-off-by: Gerald Morrison (SAP) <gerald.morrison@sap.com> Co-authored-by: Gerald Morrison (SAP) <gerald.morrison@sap.com>
On-behalf-of: Gerald Morrison (SAP) <gerald.morrison@sap.com> <!-- markdownlint-disable MD041 --> #### What this PR does / why we need it This PR improves the existing workflow that builds, tests and publishes the OCM controller and introduces a new workflow that creates releases for the controller. **build workflow:** - add on workflow_call trigger to be able to call from release workflow - remove duplicate build in different steps and replace with buidling just one multi-arch image and extract and reformat single-arch image for later use in e2e (`kind load`). Since ORAS cannot handle the correct format, skopeo is used for exactly that purpose. All other steps keep using ORAS. - Attestate all published artifacts - add floating tag "main" on push to main - Pushes to branches `releases/v*' don't publish images/charts, but only do E2E tests - Trigger "workflow_dispatch" that allows to publish/charts if OCI tests are required **release workflow:** - Align with release workflow for cli as much as possible (open-component-model#1755) - Call build workflow (build, e2e) - build and publish docker image only once and promote from RC to final release - Repackage and re-attest Helm Chart for Final release - add floating tags - "latest" for highest release (including pre-releases) - "stable" for highest final release <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Introduced a two-phase release process (Release Candidate and Final Release) with automated tag management, artifact promotion, and provenance attestation. * Added OCI image digest support to Helm charts for enhanced image reference flexibility. * Implemented automated changelog generation and release notes publishing. * **Chores** * Updated default controller image versions from "latest" to "0.0.0-main". * Expanded build and release workflows with multi-stage architecture including build, testing, publishing, and conformance stages. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Signed-off-by: Gerald Morrison (SAP) <gerald.morrison@sap.com> Co-authored-by: Gerald Morrison (SAP) <gerald.morrison@sap.com>
On-behalf-of: Gerald Morrison (SAP) <gerald.morrison@sap.com> <!-- markdownlint-disable MD041 --> #### What this PR does / why we need it This PR improves the existing workflow that builds, tests and publishes the OCM controller and introduces a new workflow that creates releases for the controller. **build workflow:** - add on workflow_call trigger to be able to call from release workflow - remove duplicate build in different steps and replace with buidling just one multi-arch image and extract and reformat single-arch image for later use in e2e (`kind load`). Since ORAS cannot handle the correct format, skopeo is used for exactly that purpose. All other steps keep using ORAS. - Attestate all published artifacts - add floating tag "main" on push to main - Pushes to branches `releases/v*' don't publish images/charts, but only do E2E tests - Trigger "workflow_dispatch" that allows to publish/charts if OCI tests are required **release workflow:** - Align with release workflow for cli as much as possible (open-component-model#1755) - Call build workflow (build, e2e) - build and publish docker image only once and promote from RC to final release - Repackage and re-attest Helm Chart for Final release - add floating tags - "latest" for highest release (including pre-releases) - "stable" for highest final release <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Introduced a two-phase release process (Release Candidate and Final Release) with automated tag management, artifact promotion, and provenance attestation. * Added OCI image digest support to Helm charts for enhanced image reference flexibility. * Implemented automated changelog generation and release notes publishing. * **Chores** * Updated default controller image versions from "latest" to "0.0.0-main". * Expanded build and release workflows with multi-stage architecture including build, testing, publishing, and conformance stages. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Signed-off-by: Gerald Morrison (SAP) <gerald.morrison@sap.com> Co-authored-by: Gerald Morrison (SAP) <gerald.morrison@sap.com> Signed-off-by: Gerald Morrison (SAP) <gerald.morrison@sap.com>
What this PR does / why we need it
Implements a unified CLI release workflow with environment-gated promotion. RC and final release happen in a single workflow run, separated by a 14-day wait timer and required approval.
Key Changes
cli/releaseenvironment with 14-day wait + reviewer approvalgh attestation verify(no bundle exports)release-versioning.jsand unit tests for all release related versioning calculationsDocumentation
See
RELEASE_PROCESS.mdfor the complete release manager guide.