Kubernetes deployment file is creating opencost namespace but not using it
In Kubernetes deployment file, Following resources/objects are being created:
-
opencostNamesapce -
opencostSA -
opencostClusterRole -
opencostClusterRoleBinding -
opencostDeployment -
opencostService
All the resources/objects do not contain the namespace definition. It is pretty much confusing as we are creating namespace from inside the file, yet we are providing --namespace opencost parameter in the kubectl command, rather than defining the namespace for various resources/objects inside their definition YAMLs respectively.
Let's say user needs to change a few things, he/she will be bound to set --namespace argument all the time, and it is a bit of rework.
What can be done to fix it? We can set the namespace of all the resources/objects inside the file.
Hello @amar-chand, thank you for raising this! We will consider this improvement when revisiting our Kubernetes resource definitions.
Everything's in opencost now.