-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
Fix several Helm YAML issues with extraModules and extraInitContainers #9709
Conversation
This issue is currently awaiting triage. If Ingress contributors determines this is a relevant issue, they will accept it by applying the The 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/test-infra repository. |
Welcome @ajacques! |
Hi @ajacques. Thanks for your PR. I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. 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/test-infra repository. |
I am still checking but allowing any/every possible container as initContainer or sideCar etc is a security concern. |
For context: I don't have any custom modules, just trying to use the OTEL one. This came up because I tried to enable OTEL on a DaemonSet and found a few different bugs that prevented me from doing that and I just fixed them all.
Can you clarify why this is something to protect the user against? This is the current state since there's no restrictions on extraInitContainers or extraContainers. |
@ajacques sorry for confusion
|
@ajacques the controller as a daemonset with OTEL would also require tests |
Unknown CLA label state. Rechecking for CLA labels. Send feedback to sig-contributor-experience at kubernetes/community. /check-cla |
@longwuyuan, Otel doesn't rely on extra modules anymore. daemonset changes for Otel looks fine, I haven't tested daemonset with Otel module though. |
Unknown CLA label state. Rechecking for CLA labels. Send feedback to sig-contributor-experience at kubernetes/community. /check-cla |
/check-cla |
Are these changes valuable? Should I remove extraModules or change anything? At the very minimum, I'd suggest we fix the extraModules indention issue, but I'm not really blocked on this change getting merged. |
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: ajacques, strongjz 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 |
What this PR does / why we need it:
Prior to this fix, users are unable to use OpenTelemetry with DaemonSets due to several issues and not able to specify both values for both extraInitContainers and extraModules. The resulting template will be rejected because it's semantically invalid due to a YAML indention issue. In addition, there's a casing issue. The Deployment refers to
image
andname
, but DaemonSet usesImage
andName
.Given the following
values.yaml
:Prior to this change, the DaemonSet gets generated like this:
After this change, it generates a correct YAML:
Honestly, I'm not sure if extraModules even works in the Deployment case. I wasn't able to do Helm template if I generated a Deployment or DaemonSet. Trying to generate a Deployment gave me:
I only discovered this issue because the DaemonSet didn't support specifying
controller.opentelemetry.enabled=true
Types of changes
Which issue/s this PR fixes
How Has This Been Tested?
I manually reviewed the generated template (see above) and deployed this commit to my cluster and verified the DaemonSet looks correct.
Are there any Helm tests that actually assert anything? I see the files in
charts/ingress-nginx/ci
, but I didn't see any expected values to make sure that's correct.Checklist:
Does my pull request need a release note?
Any user-visible or operator-visible change qualifies for a release note. This could be a:
No release notes are required for changes to the following:
For more tips on writing good release notes, check out the Release Notes Handbook