-
Notifications
You must be signed in to change notification settings - Fork 242
Fix namespace target customization support with no defaults #3052
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
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
de85973
to
61f9f53
Compare
manno
reviewed
Nov 7, 2024
manno
approved these changes
Nov 7, 2024
These tests now verify that the created namespace does bear expected labels and annotations. This commit also paves the way for additional tests with customizations over unconfigured namespace labels and annotations, which currently cause a panic.
This prevents panics when namespace labels or annotations are configured as target customizations over nonexistent defaults.
The required changes made in that repo have been merged.
95af638
to
f396966
Compare
manno
reviewed
Nov 7, 2024
|
||
// initialiseOptionsMaps initialises options and staged options maps of namespace labels and annotations on bd, if | ||
// needed. | ||
// Assumes that bd is not nil. |
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.
nit: At this point we could just pass spec?
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.
Oh, indeed we could!
manno
approved these changes
Nov 7, 2024
manno
pushed a commit
that referenced
this pull request
Nov 7, 2024
* Improve namespace target customization tests These tests now verify that the created namespace does bear expected labels and annotations. This commit also paves the way for additional tests with customizations over unconfigured namespace labels and annotations, which currently cause a panic. * Initialise options maps when empty This prevents panics when namespace labels or annotations are configured as target customizations over nonexistent defaults. * Use main branch of `rancher/fleet-test-data The required changes made in that repo have been merged.
thardeck
pushed a commit
that referenced
this pull request
Nov 8, 2024
* Improve namespace target customization tests These tests now verify that the created namespace does bear expected labels and annotations. This commit also paves the way for additional tests with customizations over unconfigured namespace labels and annotations, which currently cause a panic. * Initialise options maps when empty This prevents panics when namespace labels or annotations are configured as target customizations over nonexistent defaults. * Use main branch of `rancher/fleet-test-data The required changes made in that repo have been merged.
weyfonk
added a commit
to weyfonk/fleet
that referenced
this pull request
Nov 15, 2024
…3052) * Improve namespace target customization tests These tests now verify that the created namespace does bear expected labels and annotations. This commit also paves the way for additional tests with customizations over unconfigured namespace labels and annotations, which currently cause a panic. * Initialise options maps when empty This prevents panics when namespace labels or annotations are configured as target customizations over nonexistent defaults. * Use main branch of `rancher/fleet-test-data The required changes made in that repo have been merged.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This initialises maps in bundle deployment options when those are empty due to no default configuration being provided.
As a results, this prevents panics when namespace labels or annotations are set as target customizations without default, all-targets configuration.
Refers to #2441
Depends on rancher/fleet-test-data#23.