Skip to content

unable to use namespace added directly to a logical cluster  #157

@TheRealHaoLiu

Description

@TheRealHaoLiu

when a namespace is created on the logical cluster and not created on the KCP admin cluster no resource can be created on in the namespace

step to reproduce:

  • ensure that the .kcp directory is empty (prevent contamination from existing data in etcd)
rm -rf .kcp
  • compile and run kcp
make build
./bin/kcp start
  • set kubeconfig to KCP
export KUBECONFIG=.kcp/data/admin.kubeconfig
  • switch context to user
kubectl use-context user
  • add deployment crd
kubectl apply -f ./contrib/crds/apps/apps_deployments.yaml
  • create deployment
kubectl apply -f ./contrib/examples/deployment.yaml
  • create namespace default
kubectl create namespace default
  • receive the following error
Error from server (NotFound): error when creating "./contrib/examples/deployment.yaml": namespaces "yoloswag" not found

the above scenario have been performed for non "default" namespace with the same result

further experimentation show that after a namespace is created on the admin cluster the namespace can than be use by other logical cluster

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions