nephio-project / nephio

Nephio is a Kubernetes-based automation platform for deploying and managing highly distributed, interconnected workloads such as 5G Network Functions, and the underlying infrastructure on which those workloads depend.
Apache License 2.0
93 stars 52 forks source link

wrong repository name is shown in packagerevision list when same repository is registered in 2 namespaces #725

Closed s375kuma closed 2 weeks ago

s375kuma commented 2 months ago

Hi,

Here I have registered one git repo in 2 namespaces with different repo names. example: $ kubectl get repositories.config.porch.kpt.dev -n shiv NAME TYPE CONTENT DEPLOYMENT READY ADDRESS hello-git-c74qf-6sgrv git Package True https://github.com/blueprint/hw-profile.git

$ kubectl get repositories.config.porch.kpt.dev -n demo NAME TYPE CONTENT DEPLOYMENT READY ADDRESS hello-git-wc7xp-ljpnj git Package True https://github.com/blueprint/hw-profile.git

when I do packagerevision list for shiv namespace, I get correct result

$ kubectl get packagerevision -n shiv | grep "hello-git-c74qf-6sgrv" hello-git-c74qf-6sgrv-a48a7b45988e20f08a373e31f31c475970a1746d helloworld-profile v1 main false Published hello-git-c74qf-6sgrv hello-git-c74qf-6sgrv-518fc23ece3704a366be6522ddc6791b72471582 helloworld-profile v1 v1 true Published hello-git-c74qf-6sgrv

but for the demo namespace, I am getting wrong repository name

$ kubectl get packagerevision -n demo NAME PACKAGE WORKSPACENAME REVISION LATEST LIFECYCLE REPOSITORY hello-git-c74qf-6sgrv-a48a7b45988e20f08a373e31f31c475970a1746d helloworld-profile v1 main false Published hello-git-c74qf-6sgrv hello-git-c74qf-6sgrv-518fc23ece3704a366be6522ddc6791b72471582 helloworld-profile v1 v1 true Published hello-git-c74qf-6sgrv

Here instead of referring the hello-git-wc7xp-ljpnj repository registered in demo namespace, it is referring hello-git-c74qf-6sgrv which is registered in shiv namespace and not accessible to demo namespace.

Can we have the same repository linking which is registered for the namespace?

Thanks.