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
Fixes #24263 - Added managed content medium provider #7531
Conversation
Instead of monkey patching Redhat class, created a medium provider to be used in foreman.
Issues: #24263 |
end | ||
|
||
def medium_uri(path = "") | ||
kickstart_repo = entity.try(:content_facet).try(:kickstart_repository) || entity.try(:kickstart_repository) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder what happens when the kickstart repository is not set. Where is the mechanism that would fallback to the original Foreman's behavior?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's outside of a specific provider. The providers are chosen based on the result of #validate
call.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, ok
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks nice and clean, haven't tested Katello part but I am going to merge the core patch now, its good time post 1.19 branching.
Hello Katello devs I just merged the core part which will likely break your tests, this PR fixes it! @ShimShtein @iNecas @jlsherrill and perhaps @parthaa ... |
[test katello] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @ShimShtein, works great!
@ShimShtein++ @jlsherrill++ thanks folks! That was smooth. |
Instead of monkey patching Redhat class, created a medium provider to be used in foreman.
This PR should be merged after theforeman/foreman#5244 is merged. It changes the way medium_uri is obtained for a host.