Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

AnyNamespace Multi ArgoCD Instance WildCard Application Resource Monitoring Overlap #19016

Closed
3 tasks done
ArthurVardevanyan opened this issue Jul 10, 2024 · 1 comment
Closed
3 tasks done
Labels
bug Something isn't working component:core Syncing, diffing, cluster state cache type:bug

Comments

@ArthurVardevanyan
Copy link
Contributor

ArthurVardevanyan commented Jul 10, 2024

Here is a PR with my attempt at solving the below scenario: #19017

Checklist:

  • I've searched in the docs and FAQ for my answer: https://bit.ly/argocd-faq.
  • I've included steps to reproduce the bug.
  • I've pasted the output of argocd version.

Describe the bug

Two Cluster Wide ArgoCD Instances are present on a given cluster.

1 For Managing the Cluster and its resources.
1 For Tenants of the Cluster to manage their resources.

Second Tenant ArgoCD uses the application in any namespace feature.

The issue is, when using * for the selector, due to there being an unkown number of namespaces. That second instance tries to all scan and reconcile the applications already managed by the first instance.

To Reproduce
Example of the cluster config.
https://github.com/ArthurVardevanyan/HomeLab/blob/main/kubernetes/argocd/base/argocd.yaml

Example of a tenant config:
https://github.com/ArthurVardevanyan/HomeLab/blob/main/kubernetes/argocd/apps/argocd-apps.yaml#L14-L18
For the moment in the example above, the namespaces are explicitly defined. However on larger environments, we will require *

Expected behavior

I would expect ArgoCD to be aware of an application/object is already monitored by another instance, and not monitor it.

However, a simpler solution would be an exclude namespace list option.

Version
2.11.2: https://github.com/ArthurVardevanyan/HomeLab/blob/main/kubernetes/argocd/apps/argocd-apps.yaml#L57

@ArthurVardevanyan ArthurVardevanyan added the bug Something isn't working label Jul 10, 2024
@alexmt alexmt added component:core Syncing, diffing, cluster state cache type:bug labels Jul 10, 2024
jannfis pushed a commit that referenced this issue Aug 13, 2024
* feat(sourceNamespace): Regex Support

Signed-off-by: Arthur <arthur@arthurvardevanyan.com>

* feat(sourceNamespace): Separate exactMatch into patternMatch

Signed-off-by: Arthur <arthur@arthurvardevanyan.com>

---------

Signed-off-by: Arthur <arthur@arthurvardevanyan.com>
@jannfis
Copy link
Member

jannfis commented Aug 13, 2024

Implemented by #19017

@jannfis jannfis closed this as completed Aug 13, 2024
reggie-k pushed a commit to reggie-k/argo-cd that referenced this issue Aug 14, 2024
* feat(sourceNamespace): Regex Support

Signed-off-by: Arthur <arthur@arthurvardevanyan.com>

* feat(sourceNamespace): Separate exactMatch into patternMatch

Signed-off-by: Arthur <arthur@arthurvardevanyan.com>

---------

Signed-off-by: Arthur <arthur@arthurvardevanyan.com>
ChichiCaleb pushed a commit to ChichiCaleb/argo-cd that referenced this issue Aug 15, 2024
* feat(sourceNamespace): Regex Support

Signed-off-by: Arthur <arthur@arthurvardevanyan.com>

* feat(sourceNamespace): Separate exactMatch into patternMatch

Signed-off-by: Arthur <arthur@arthurvardevanyan.com>

---------

Signed-off-by: Arthur <arthur@arthurvardevanyan.com>
Signed-off-by: ChichiCaleb <ChichiCaleb@chichiuchenna@gmail.com>
ChichiCaleb pushed a commit to ChichiCaleb/argo-cd that referenced this issue Aug 15, 2024
* feat(sourceNamespace): Regex Support

Signed-off-by: Arthur <arthur@arthurvardevanyan.com>

* feat(sourceNamespace): Separate exactMatch into patternMatch

Signed-off-by: Arthur <arthur@arthurvardevanyan.com>

---------

Signed-off-by: Arthur <arthur@arthurvardevanyan.com>
Signed-off-by: ChichiCaleb <ChichiCaleb@chichiuchenna@gmail.com>
Signed-off-by: ChichiCaleb <chichiuchenna@gmail.com>
gcp-cherry-pick-bot bot pushed a commit that referenced this issue Aug 23, 2024
* feat(sourceNamespace): Regex Support

Signed-off-by: Arthur <arthur@arthurvardevanyan.com>

* feat(sourceNamespace): Separate exactMatch into patternMatch

Signed-off-by: Arthur <arthur@arthurvardevanyan.com>

---------

Signed-off-by: Arthur <arthur@arthurvardevanyan.com>
jannfis pushed a commit that referenced this issue Aug 23, 2024
* feat(sourceNamespace): Regex Support



* feat(sourceNamespace): Separate exactMatch into patternMatch



---------

Signed-off-by: Arthur <arthur@arthurvardevanyan.com>
Co-authored-by: Arthur Vardevanyan <arthur@arthurvardevanyan.com>
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
bug Something isn't working component:core Syncing, diffing, cluster state cache type:bug
Projects
None yet
Development

No branches or pull requests

3 participants