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

Add Namesapces to Chart #120

Open
2 tasks done
foertel opened this issue Sep 11, 2023 · 4 comments · May be fixed by #144
Open
2 tasks done

Add Namesapces to Chart #120

foertel opened this issue Sep 11, 2023 · 4 comments · May be fixed by #144

Comments

@foertel
Copy link

foertel commented Sep 11, 2023

Preflight Checklist

  • I agree to follow the Code of Conduct that this project adheres to.
  • I have searched the issue tracker for an issue that matches the one I want to file, without success.

Problem Description

The objects generated by Helm do not wear a Namespace. There is no way to specify one, as Helm's namespace argument is pretty inconsistent.

Proposed Solution

Add Namespace-properties to all object's yaml wrapped in a condition. This would give the opportunity to set the namespace using Values and would otherwise not affect at all.

Alternatives Considered

Export objects with helm template and specify -n on kubectl. Does not really go with most GitOps flows.

Additional Information

No response

@foertel
Copy link
Author

foertel commented Sep 11, 2023

If anyone would give a thumbs up on the idea, I'd happily provide an MR.

Helm also suggests to do it this way, if you wanna use namespaces.
helm/helm#3553

@sagikazarmark
Copy link
Member

What's the added value of adding namespaces to the resources? From what I can tell, most GitOps tools can already deploy to namespaces.

@foertel
Copy link
Author

foertel commented Sep 12, 2023

When using GitOps tools many of us use helm template to render the chart(*) and thus need to specify the namespace anyway, because otherwise the selectors (like RoleBinding) will be broken. But then we'd end up with manifests, that point selectors to one namespace but still can be deployed to another. We basically have to keep the namespace configuration in two different locations.

It feels inconsistent to have namespaces in part of the manifests but not others.

(*) Many of us even render the manifests first and commit them for review to have a better understanding of what's going to happen in CI.

@jbertozzi
Copy link

Many users (including me) complain about the missing namespace in helm template. Having helm install --namespace and helm template --namespace behaving differently seems wrong.

helm/helm#3553

@peschmae peschmae linked a pull request Sep 5, 2024 that will close this issue
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants