Introduce namespace to environments
Environments currently have the concept of a server URI, but it is ambiguous which cluster namespace to use. This commit will introduce the concept of namespaces to the env commands. For example, `kubecfg env add staging http://mock-staging-uri \ --namespace=staging-namespace` `kubecfg env set staging --namespace=staging-namespace` The default environment will use the namespace of the default context. This commit will also update commands that take the <env> arg such as `apply` to make use of the env namespace, if specified.
Showing
- cmd/apply.go 1 addition, 1 deletioncmd/apply.go
- cmd/delete.go 1 addition, 1 deletioncmd/delete.go
- cmd/diff.go 1 addition, 1 deletioncmd/diff.go
- cmd/env.go 29 additions, 10 deletionscmd/env.go
- cmd/init.go 1 addition, 1 deletioncmd/init.go
- cmd/root.go 7 additions, 2 deletionscmd/root.go
- cmd/update.go 1 addition, 1 deletioncmd/update.go
- metadata/environment.go 44 additions, 33 deletionsmetadata/environment.go
- metadata/environment_test.go 9 additions, 4 deletionsmetadata/environment_test.go
- metadata/interface.go 3 additions, 3 deletionsmetadata/interface.go
- metadata/manager.go 2 additions, 3 deletionsmetadata/manager.go
- metadata/manager_test.go 5 additions, 5 deletionsmetadata/manager_test.go
- pkg/kubecfg/apply.go 4 additions, 4 deletionspkg/kubecfg/apply.go
- pkg/kubecfg/delete.go 4 additions, 4 deletionspkg/kubecfg/delete.go
- pkg/kubecfg/diff.go 4 additions, 4 deletionspkg/kubecfg/diff.go
- pkg/kubecfg/env.go 39 additions, 15 deletionspkg/kubecfg/env.go
- pkg/kubecfg/init.go 4 additions, 3 deletionspkg/kubecfg/init.go
Please register or sign in to comment