-
Notifications
You must be signed in to change notification settings - Fork 297
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 #36776 - Fixed issue where composite content views promoted to … #10752
Conversation
Issues: #36776 |
I haven't fully looked through the code yet, but I don't think the special registry naming scheme should even apply to archived repositories. The archived repositories shouldn't be exposed to users besides for debugging. While I'm guessing this stops the error, the env picked likely doesn't match the repository. Could we instead stop using the special naming scheme for archived repositories? Perhaps just ignore the registry naming pattern? |
9577664
to
ecb1d4f
Compare
I implemented the suggestions we talked about in our PM, meaning if the environment does not exist (as in archived repos), render the name as if a pattern is not provided. I reworked the logic a little to make it easier to understand and added a big table in the documentation to explain everything. |
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 haven't tested it, but the logic looks solid to me! Thanks for the table.
cbc68e0
to
81ae607
Compare
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.
Functionality-wise it works like a charm
2ddbfa2
to
b44a866
Compare
…lifecycle environments referencing the env name would error on promotion. Changed env replacement source. Force pushing to rerun tests. Rubocop fixes Changed several factors for how the container name is rendered. Documented thought process. Fixed existing unit test to test on new naming schema instead of testing for overlap with a poor env pattern. Rubocop fixes Added test to check for docker repo container name overlap. Modified documentation to rerun tests. Rubocop fixes
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.
Ship it!
…lifecycle environments referencing the env name would error on promotion.
Changed env replacement source.
What are the changes introduced in this pull request?
Composite content views containing archived repositories have their environment set to nil. When promoting this CVV to a lifecycle environment with a registry name containing the lifecycle environment's name, this would previously cause the action to error out. After the changes, if the env is unset, Katello will use a different naming schema to name containers. This should only impact archived repositories.
Considerations taken when implementing this change?
I reworked a little logic in
app/models/katello/repository.rb
. There is a truth table in the comments which shows the decisions taken.What are the testing steps for this pull request?
<%= repository.name %>
.<%= lifecycle_environment.label %>/<%= repository.name %>