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

helm: Add Support for Namespace Override #24445

Closed
wants to merge 2 commits into from

Conversation

pr0PM
Copy link

@pr0PM pr0PM commented Mar 18, 2023

Please ensure your pull request adheres to the following guidelines:

  • For first time contributors, read Submitting a pull request
  • All code is covered by unit and/or runtime tests where feasible.
  • All commits contain a well written commit description including a title,
    description and a Fixes: #XXX line if the commit addresses a particular
    GitHub issue.
  • If your commit description contains a Fixes: <commit-id> tag, then
    please add the commit author[s] as reviewer[s] to this issue.
  • All commits are signed off. See the section Developer’s Certificate of Origin
  • Provide a title or release-note blurb suitable for the release notes.
  • [] Are you a user of Cilium? Please add yourself to the Users doc
  • Thanks for contributing!

This is helpful while deploying charts using gitOps tools like argoCD. Usually a standard among all the charts.

  • Patch for the helper.tpl priority class issue
  • document generation steps
  • spellcheck allowlist
  • make install/kubernetes

Fixes: #20511

Signed-off-by: Prateek Mishra pr0PM@pm.me

Add namespace override support in cilium charts

@pr0PM pr0PM requested review from a team as code owners March 18, 2023 13:31
@pr0PM pr0PM requested a review from squeed March 18, 2023 13:31
@maintainer-s-little-helper maintainer-s-little-helper bot added the dont-merge/needs-release-note-label The author needs to describe the release impact of these changes. label Mar 18, 2023
@pr0PM pr0PM requested review from chancez and qmonnet March 18, 2023 13:31
@github-actions github-actions bot added the kind/community-contribution This was a contribution made by a community member. label Mar 18, 2023
@pr0PM
Copy link
Author

pr0PM commented Mar 18, 2023

Hi @sayboras this is the same PR which broke down last time while fixing inconsistencies in my config.

@sayboras sayboras added the release-note/minor This PR changes functionality that users may find relevant to operating Cilium. label Mar 19, 2023
@maintainer-s-little-helper maintainer-s-little-helper bot removed the dont-merge/needs-release-note-label The author needs to describe the release impact of these changes. label Mar 19, 2023
@sayboras sayboras changed the title Add Support for Namespace Override helm: Add Support for Namespace Override Mar 19, 2023
@sayboras
Copy link
Member

this is the same PR which broke down last time while fixing inconsistencies in my config.

Thanks for your help. There is small failure with generated doc checking, can you run the below command and submit the changes in the same commit ?

https://github.com/cilium/cilium/actions/runs/4455626054/jobs/7829681639?pr=24445

Make sure to apply your changes to cilium/values.yaml.tmpl and run 'make -C install/kubernetes cilium/values.yaml' to regenerate.

@sayboras
Copy link
Member

/test

Copy link
Member

@qmonnet qmonnet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, thank you!

@chancez
Copy link
Contributor

chancez commented Mar 20, 2023

I can't help but feel like this needs a CI test so we can actually verify this works as expected. Do we have a good way for a contributor to add new GitHub workflows?

@squeed
Copy link
Contributor

squeed commented Mar 21, 2023

Hmm, what's the use-case for this? Out of curiosity, why is the Helm namespace not sufficient? I see mention of umbrella charts, but can you explain that a bit more?

Separately, are there other Helm conventions we should be implementing as well?

@pr0PM
Copy link
Author

pr0PM commented Mar 21, 2023

Personally I wanted to deploy cilium via argo-cd with custom values, using sync waves so that cilium is installed first.
Can't pass helm values from charts into argo-cd, so we would need to modify the argocd application spec to pass a parameter for namespace.
Would prefer to keep argocd clean as namespace override is something standard across all charts I've come across.

This is helpful while deploying charts using gitOps tools like
argoCD. Usually a standard among all the charts.

- Patch for the helper.tpl priority class issue
- document generation steps
- spellcheck allowlist
- make install/kubernetes

Fixes: cilium#20511

Signed-off-by: Prateek Mishra <pr0PM@pm.me>
@pr0PM pr0PM requested review from squeed and removed request for chancez March 27, 2023 05:43
@sayboras
Copy link
Member

sayboras commented Mar 29, 2023

/test

Job 'Cilium-PR-K8s-1.25-kernel-4.19' failed:

Click to show.

Test Name

K8sDatapathServicesTest Checks E/W loadbalancing (ClusterIP, NodePort from inside cluster, etc) Tests NodePort inside cluster (kube-proxy) with IPSec and externalTrafficPolicy=Local

Failure Output

FAIL: Request from k8s1 to service http://[fd04::11]:32610 failed

If it is a flake and a GitHub issue doesn't already exist to track it, comment /mlh new-flake Cilium-PR-K8s-1.25-kernel-4.19 so I can create one.

Job 'Cilium-PR-K8s-1.16-kernel-4.19' hit: #22578 (96.99% similarity)

@pr0PM
Copy link
Author

pr0PM commented Apr 5, 2023

Hi just following up, I hope nothing else is pending from my side.

@squeed
Copy link
Contributor

squeed commented Apr 5, 2023

I've kicked off some of the failed jobs; likely a flake but it's possible something somehow broke in the charts.

@squeed
Copy link
Contributor

squeed commented Apr 19, 2023

@pr0PM looks like this needs a rebase; then it should be good to go.

@pr0PM pr0PM requested a review from squeed April 20, 2023 12:19
@squeed
Copy link
Contributor

squeed commented Apr 20, 2023

@pr0PM can you rebase and remove the merge commits please?

Separately, I've got a PR to add a tool for testing helm invariants -- #23881 -- this would be a good thing to add a test for.

Signed-off-by: Prateek Mishra <pr0PM@pm.me>
@pr0PM
Copy link
Author

pr0PM commented Apr 23, 2023

hi can you provide steps on the kind of state we need here, i tried rebase but it didn't help in this case due to normal out of date from main and the switch from master -> main ig.
can't rebase directly on github as the update with rebase button mentions some conflicts.

Copy link
Member

@kaworu kaworu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the patch @pr0PM! This PR needs to be rebased on top of main. A couple of files were removed and there is one conflict. Also git grep Release.Namespace shows some instances of .Release.Namespace that could be updated.

@@ -4,6 +4,9 @@
# For example: 1.7, 1.8, 1.9
# upgradeCompatibility: '1.8'

# -- String to override release namespace for all resources
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we add a bit more of context here? e.g. mention that it is useful for tools that are unable to pass other Helm flags than values like argo-cd.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @pr0PM! Are you going to replace more .Release.Namespace in install/kubernetes/cilium?

@nathanjsweet
Copy link
Member

Uh oh. It looks like you created a rebase commit instead of rebasing. You might just want to create a new branch off of main and cherry-pick your commit on top of it.

@kaworu kaworu added the dont-merge/needs-rebase This PR needs to be rebased because it has merge conflicts. label Apr 28, 2023
@joestringer joestringer marked this pull request as draft May 5, 2023 16:33
@joestringer
Copy link
Member

I've marked the PR as draft while you address the feedback on the PR, feel free to click the "Ready for review" button at the bottom of the page to re-request review when you've addressed that. Thanks for your contributions!

@github-actions
Copy link

github-actions bot commented Jun 5, 2023

This pull request has been automatically marked as stale because it
has not had recent activity. It will be closed if no further activity
occurs. Thank you for your contributions.

@github-actions github-actions bot added the stale The stale bot thinks this issue is old. Add "pinned" label to prevent this from becoming stale. label Jun 5, 2023
@github-actions
Copy link

This pull request has not seen any activity since it was marked stale.
Closing.

@github-actions github-actions bot closed this Jun 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dont-merge/needs-rebase This PR needs to be rebased because it has merge conflicts. kind/community-contribution This was a contribution made by a community member. release-note/minor This PR changes functionality that users may find relevant to operating Cilium. stale The stale bot thinks this issue is old. Add "pinned" label to prevent this from becoming stale.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CFP: Add a value for overriding the namespace in the helm chart.
9 participants