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

kubernetes: Add styling based on current namespace and/or context #5911

Open
daftping opened this issue Apr 8, 2024 · 0 comments
Open

kubernetes: Add styling based on current namespace and/or context #5911

daftping opened this issue Apr 8, 2024 · 0 comments
Labels
✨ enhancement A new feature implementation.

Comments

@daftping
Copy link

daftping commented Apr 8, 2024

Feature Request

In the current implementation, it is impossible to customize the style based on the Kubernetes namespace, only the Kubernetes context is supported.
One of the common patterns is to have dev and prod namespaces on the same pool of clusters so it is impossible to change style based on the cluster name and you can rely only on the namespace name. For example:

context: foo namespace: dev-bar
context: foo namespace: prod-bar
context: baz namespace: dev-bar
context: baz namespace: prod-bar

Is your feature request related to a problem? Please describe.

Original implementation #4550

Describe the solution you'd like

[kubernetes]
format = 'on [⛵ ($user on )($cluster in )$context \($namespace\)](dimmed green) '
disabled = false
contexts = [
  { namespace_pattern = "dev-.*", style = "green", symbol = "🟢 " },
  { context_pattern = "int.*", namespace_pattern = "prod-.*", style = "yellow" },
  { namespace_pattern = "prod-.*", style = "red", symbol = "🚨 "  },
]

Describe alternatives you've considered

I am not aware of any possible workarounds

@daftping daftping added the ✨ enhancement A new feature implementation. label Apr 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
✨ enhancement A new feature implementation.
Projects
None yet
Development

No branches or pull requests

1 participant