Skip to content

Conversation

RadekManak
Copy link
Contributor

This PR enables rebasebot for cluster-api-provider-azure.

It fetches the latest release from API, extracts the release tag from it and set it as rebase source.
CAPI providers require generating customized manifests for openshift. This is achieved by using provided lifecyclehook scripts that executes the generation make target and commits changes.

I am considering moving the generation script into the azure repository, but have it here for easier testing.

@openshift-ci openshift-ci bot requested review from JoelSpeed and nrb October 11, 2024 10:11
@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Oct 11, 2024
@openshift-ci-robot openshift-ci-robot added the rehearsals-ack Signifies that rehearsal jobs have been acknowledged label Oct 11, 2024
@openshift-ci-robot openshift-ci-robot removed the rehearsals-ack Signifies that rehearsal jobs have been acknowledged label Oct 11, 2024
@RadekManak
Copy link
Contributor Author

/pj-rehearse

@openshift-ci-robot
Copy link
Contributor

@RadekManak: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@RadekManak
Copy link
Contributor Author

/pj-rehearse

@openshift-ci-robot
Copy link
Contributor

@RadekManak: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@RadekManak
Copy link
Contributor Author

/pj-rehearse

@openshift-ci-robot
Copy link
Contributor

@RadekManak: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@RadekManak
Copy link
Contributor Author

/pj-rehearse

@openshift-ci-robot
Copy link
Contributor

@RadekManak: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@RadekManak
Copy link
Contributor Author

/pj-rehearse periodic-ci-openshift-eng-rebasebot-main-cluster-api-provider-azure

@openshift-ci-robot
Copy link
Contributor

@RadekManak: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@RadekManak
Copy link
Contributor Author

/pj-rehearse periodic-ci-openshift-eng-rebasebot-main-cluster-api-provider-azure

@openshift-ci-robot
Copy link
Contributor

@RadekManak: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

Copy link
Member

@damdo damdo left a comment

Choose a reason for hiding this comment

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

Thanks for putting this together @RadekManak 👍

Looks reasonable to me. I left a couple of comments to not forget about the things we discussed.

Also we should try and fix: openshift-eng/rebasebot#56
to avoid confusion.

@damdo
Copy link
Member

damdo commented Oct 22, 2024

/assign @JoelSpeed
for approval

@JoelSpeed
Copy link
Contributor

/lgtm
/approve

@RadekManak you'll need to /pj-rehearse ack if you're happy with the rehearsal

As Dam mentions would be good to dedupe some of the scripting needed here at some point, but lets not block on that

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Oct 22, 2024
@damdo
Copy link
Member

damdo commented Oct 22, 2024

Even though the E2Es on the rebase PR are failing (likely an ASO issue).

The rebase was performed correctly. So I'm happy for @RadekManak to ack the rehearsals.

@RadekManak
Copy link
Contributor Author

/pj-rehearse ack

@openshift-ci-robot
Copy link
Contributor

@RadekManak: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@damdo
Copy link
Member

damdo commented Mar 21, 2025

/pj-rehearse periodic-ci-openshift-eng-rebasebot-main-cluster-api-provider-aws

@openshift-ci-robot
Copy link
Contributor

@damdo: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@JoelSpeed
Copy link
Contributor

Is this ready to be merged?

UPSTREAM_VERSION=$(curl --silent --header "X-GitHub-Api-Version:2022-11-28" "https://api.github.com/repos/kubernetes-sigs/cluster-api-provider-vsphere/releases" | grep '"tag_name":' | grep -v alpha | grep -v beta | grep -v rc | sed -E 's/.*"([^"]+)".*/\1/' | sed '/-/!{s/$/_/}' | sort -V | sed 's/_$//' | tail -n1)
rebasebot --source kubernetes-sigs/cluster-api-provider-vsphere:"${UPSTREAM_VERSION}" \
--dest openshift/cluster-api-provider-vsphere:master \
--rebase openshift-cloud-team/cluster-api-provider-vsphere:rebase-bot-master \
Copy link
Member

Choose a reason for hiding this comment

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

I think we could change the rebase-bot-master branch name here to something different, which encompasses the version computed. So we can have multiple PRs based on different versions, e.g. for syncing older release branches with newer upstream releases.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I am thinking we extend this to be rebase-bot-<target_branch>. We could make this the default when the rebase branch is not specified. For now, I have updated to rebase-bot-main where the dest branch is main.

@damdo
Copy link
Member

damdo commented Mar 26, 2025

/pj-rehearse periodic-ci-openshift-eng-rebasebot-main-cluster-api-provider-aws

@openshift-ci-robot
Copy link
Contributor

@damdo: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

Copy link
Contributor Author

@RadekManak RadekManak left a comment

Choose a reason for hiding this comment

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

Updated to use the --source-ref-hook script.

UPSTREAM_VERSION=$(curl --silent --header "X-GitHub-Api-Version:2022-11-28" "https://api.github.com/repos/kubernetes-sigs/cluster-api-provider-vsphere/releases" | grep '"tag_name":' | grep -v alpha | grep -v beta | grep -v rc | sed -E 's/.*"([^"]+)".*/\1/' | sed '/-/!{s/$/_/}' | sort -V | sed 's/_$//' | tail -n1)
rebasebot --source kubernetes-sigs/cluster-api-provider-vsphere:"${UPSTREAM_VERSION}" \
--dest openshift/cluster-api-provider-vsphere:master \
--rebase openshift-cloud-team/cluster-api-provider-vsphere:rebase-bot-master \
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I am thinking we extend this to be rebase-bot-<target_branch>. We could make this the default when the rebase branch is not specified. For now, I have updated to rebase-bot-main where the dest branch is main.

@openshift-ci-robot
Copy link
Contributor

[REHEARSALNOTIFIER]
@RadekManak: the pj-rehearse plugin accommodates running rehearsal tests for the changes in this PR. Expand 'Interacting with pj-rehearse' for usage details. The following rehearsable tests have been affected by this change:

Test name Repo Type Reason
periodic-ci-openshift-eng-rebasebot-main-cloud-provider-aws N/A periodic Ci-operator config changed
periodic-ci-openshift-eng-rebasebot-main-cloud-provider-azure N/A periodic Ci-operator config changed
periodic-ci-openshift-eng-rebasebot-main-cluster-api-provider-gcp N/A periodic Periodic changed
periodic-ci-openshift-eng-rebasebot-main-cluster-api-provider-aws N/A periodic Periodic changed
periodic-ci-openshift-eng-rebasebot-main-cluster-api N/A periodic Periodic changed
periodic-ci-openshift-eng-rebasebot-main-cloud-provider-vsphere N/A periodic Ci-operator config changed
periodic-ci-openshift-eng-rebasebot-main-cloud-provider-gcp N/A periodic Ci-operator config changed
periodic-ci-openshift-eng-rebasebot-main-cloud-provider-ibm N/A periodic Ci-operator config changed
periodic-ci-openshift-eng-rebasebot-main-cluster-api-provider-ibmcloud N/A periodic Periodic changed
periodic-ci-openshift-eng-rebasebot-main-cluster-api-provider-azure N/A periodic Periodic changed
periodic-ci-openshift-eng-rebasebot-main-cluster-api-provider-vsphere N/A periodic Periodic changed
Interacting with pj-rehearse

Comment: /pj-rehearse to run up to 5 rehearsals
Comment: /pj-rehearse skip to opt-out of rehearsals
Comment: /pj-rehearse {test-name}, with each test separated by a space, to run one or more specific rehearsals
Comment: /pj-rehearse more to run up to 10 rehearsals
Comment: /pj-rehearse max to run up to 25 rehearsals
Comment: /pj-rehearse auto-ack to run up to 5 rehearsals, and add the rehearsals-ack label on success
Comment: /pj-rehearse list to get an up-to-date list of affected jobs
Comment: /pj-rehearse abort to abort all active rehearsals
Comment: /pj-rehearse network-access-allowed to allow rehearsals of tests that have the restrict_network_access field set to false. This must be executed by an openshift org member who is not the PR author

Once you are satisfied with the results of the rehearsals, comment: /pj-rehearse ack to unblock merge. When the rehearsals-ack label is present on your PR, merge will no longer be blocked by rehearsals.
If you would like the rehearsals-ack label removed, comment: /pj-rehearse reject to re-block merging.

@RadekManak
Copy link
Contributor Author

/pj-rehearse periodic-ci-openshift-eng-rebasebot-main-cloud-provider-aws

@openshift-ci-robot
Copy link
Contributor

@RadekManak: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@RadekManak
Copy link
Contributor Author

/pj-rehearse periodic-ci-openshift-eng-rebasebot-main-cluster-api-provider-aws

@openshift-ci-robot
Copy link
Contributor

@RadekManak: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@JoelSpeed
Copy link
Contributor

@RadekManak Are we able to merge this soon?

@RadekManak
Copy link
Contributor Author

/pj-rehearse periodic-ci-openshift-eng-rebasebot-main-cluster-api-provider-aws

@openshift-ci-robot
Copy link
Contributor

@RadekManak: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@RadekManak
Copy link
Contributor Author

/pj-rehearse ack

@openshift-ci-robot
Copy link
Contributor

@RadekManak: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@openshift-ci-robot openshift-ci-robot added the rehearsals-ack Signifies that rehearsal jobs have been acknowledged label Apr 22, 2025
@RadekManak
Copy link
Contributor Author

RadekManak commented Apr 23, 2025

@JoelSpeed I think we can merge now.
@damdo is not here to respond to my change to rebase branch naming, but we can adjust it in follow-up PR when we think about setting up release branch rebases.

@JoelSpeed
Copy link
Contributor

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Apr 23, 2025
Copy link
Contributor

openshift-ci bot commented Apr 23, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: JoelSpeed, RadekManak

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Copy link
Contributor

openshift-ci bot commented Apr 23, 2025

@RadekManak: all tests passed!

Full PR test history. Your PR dashboard.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

@openshift-merge-bot openshift-merge-bot bot merged commit 592c996 into openshift:master Apr 23, 2025
17 checks passed
ctartici pushed a commit to ctartici/release_ctartici that referenced this pull request Apr 28, 2025
…i providers (openshift#57749)

* Setup rebasebot to rebase cluster api repositories

* Change rebasebot rebase branch name to align with dest branch
mehabhalodiya pushed a commit to mehabhalodiya/release that referenced this pull request Apr 29, 2025
…i providers (openshift#57749)

* Setup rebasebot to rebase cluster api repositories

* Change rebasebot rebase branch name to align with dest branch
Neilhamza pushed a commit to Neilhamza/release that referenced this pull request May 5, 2025
…i providers (openshift#57749)

* Setup rebasebot to rebase cluster api repositories

* Change rebasebot rebase branch name to align with dest branch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. lgtm Indicates that a PR is ready to be merged. rehearsals-ack Signifies that rehearsal jobs have been acknowledged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants