Open sthomson-wyn opened 3 weeks ago
/assign
@sthomson-wyn I am having a hard time to understand your issue with the partial screenshots. So let me try to summarize and correct me if I'm wrong! You have a manifest in your application that is a ClusterRole like the one below. When you sync this resource in an application, it is returned twice in the argocd app get
command?
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: storefront
rules:
- apiGroups: [""]
resources: ["example"]
verbs: ["get", "watch", "list"]
@sthomson-wyn Does the duplicate resource appear in UI as well?
@agaudreault When the resource has a namespace defined
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: storefront
namespace: some-namespace
rules:
- apiGroups: [""]
resources: ["example"]
verbs: ["get", "watch", "list"]
It appears twice from the argocd app get
command, but not in the UI @thecooldrop
Checklist:
argocd version
.Describe the bug
When creating a Cluster scoped resource (Like a ClusterRole or ClusterRoleBinding), the application tracks the resource as 2 distinct resources. Due to this,
argocd app get
incorrectly reports them as having a "Running" sync statusTo Reproduce
Add a ClusterRole to an application that also has a namespace
Expected behavior
I think ideally ArgoCD would just ignore the namespace?
Screenshots
(namespace hidden)
Since the tree output doesn't have the namespaces, only one shows up https://github.com/argoproj/argo-cd/blob/48eb7f3608b129c299f8e1a8eddbda2971c8f94e/cmd/argocd/commands/tree.go#L33
Version