question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

func kubernetes deploy should deploy to the current namespace, not the default

See original GitHub issue

func kubernetes deploy should deploy to the current namespace, not the default.

Current behavior

Currently, func kubernetes deploy always specifies namespace: default.

Expected behavior

I would expect it to omit the namespace since it was not specified so that it uses the default namespace from KUBECONFIG instead.

Other

I know --namespace allows you to specify a namespace but I would propose to leave out the namespace if it’s not specified instead as it is confusing.

You can set a different namespace as following:

k config set-context kubernetes-demos --namespace microservices-with-apim

Happy to contribute this if people agree.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:1
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
tomkerkhovecommented, Feb 10, 2021

I’m happy to pick this up, but could be a few days; if OK

Read more comments on GitHub >

github_iconTop Results From Across the Web

Kubernetes service deploying in default namespace ...
The most likely issue here is that the Chart already specifies default as metadata.namespace which in Helm 2 is not overwritten by the ......
Read more >
Kubernetes best practices: Specifying Namespaces in YAML
Managing your active Namespace​​ Out of the box, your active namespace is the “default” namespace. Unless you specify a Namespace in the YAML, ......
Read more >
Deployments
A Deployment manages a set of Pods to run an application workload, usually one that doesn't maintain state.
Read more >
argocd CLI uses wrong namespace · Issue #9123
The argocd CLI uses the kubernetes default namespace. For example, "argocd app list" will return an empty list, if current namespace is not...
Read more >
Gateway UI assumes openfaas-fn is the default namespace
Current Behaviour. The ui can not deploy functions unless you explicitly deploy with the openfaas-fn namespace. Steps to Reproduce (for bugs).
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found