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

Pin Foreman's CI to stable branches on branching #447

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ekohl
Copy link
Member

@ekohl ekohl commented Nov 12, 2024

I'm not entirely happy with this, because it makes it interactive. I don't see another way, though it should be noted we may have more cases where we need to know the Katello version when branching. For example, jenkins-jobs but maybe more.

@evgeni
Copy link
Member

evgeni commented Nov 13, 2024

Should the Katello part be a step in the Katello branching?
Or could we fetch/parse https://github.com/Katello/katello/blob/master/lib/katello/version.rb on the fly? (Assuming Katello is never branched before Foreman)

(Not saying those are good ideas, but wanted to throw them regardless)

@ekohl
Copy link
Member Author

ekohl commented Nov 13, 2024

I was thinking about introducing KATELLO_VERSION in settings, similar to how we have FOREMAN_VERSION:

Might not be pretty, but feels like the most reliable thing.

For example, jenkins-jobs but maybe more.

Today we have:

- [ ] Open a PR with the result of [jenkins-jobs](https://github.com/theforeman/jenkins-jobs) branching: `./branch-foreman <%= release %> KATELLO_VERSION`

- [ ] Update `katello_version` in `package_manifest.yaml` on the `rpm/<%= release %>` branch: `sed -i '/katello_version:/ s/nightly/KATELLO_VERSION_HERE/' package_manifest.yaml`

So we already need it in 2 places. Isn't 3 the magic number to properly fix it?

Also, we can probably use the same approach to update https://github.com/Katello/katello/blob/d07494f4dba5f32f4673eb78ada8e36bacfa985d/.github/workflows/ruby.yml#L30 in an automated way.

@evgeni
Copy link
Member

evgeni commented Nov 13, 2024

Hmm, can't we enumerate over all releases/katello/*/settings and find the one that has the right FOREMAN_VERSION?

Otherwise it seems like we're pointing in circles

image

@ekohl
Copy link
Member Author

ekohl commented Nov 13, 2024

Hmm, can't we enumerate over all releases/katello/*/settings and find the one that has the right FOREMAN_VERSION?

I thought about that, but it felt a bit magical

Otherwise it seems like we're pointing in circles

I wasn't thinking about loading the Katello settings, but yes, it's a bit redundant.

Thinking higher level, we could restructure things to have a sub-project. So PROJECT=foreman SUBPROJECT=katello or PROJECT=foreman SUBPROJECT=client. Not sure I want to go in that direction now, but it could simplify our inheritance loading by swapping it around.

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