Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

ignoreDifferences is not automatically refreshed. #12610

Closed
3 tasks done
mulhotavares opened this issue Feb 24, 2023 · 1 comment · Fixed by #12607
Closed
3 tasks done

ignoreDifferences is not automatically refreshed. #12610

mulhotavares opened this issue Feb 24, 2023 · 1 comment · Fixed by #12607
Labels
bug Something isn't working

Comments

@mulhotavares
Copy link

mulhotavares commented Feb 24, 2023

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
When applying a helm chart that only contains CRDs, it will show OutOfSync due to a diff in the manifests.
When I add the ignoreDifferences to ignore that mismatch, and hit Sync, the application still shows as OutOfSync, until I click refresh.

To Reproduce
Create a new App via UI. Click Edit as YAML. Paste this code:

apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
  name: my-test-app
spec:
  destination:
    namespace: test-crds
    server: 'https://kubernetes.default.svc'
  source:
    repoURL: 'https://helm.linkerd.io/stable'
    targetRevision: 1.4.0
    chart: linkerd-crds
  project: cluster-infra
  syncPolicy:
    automated: null
    syncOptions:
      - CreateNamespace=true

Then Save, Create, and Sync.
After sync, everything will be OutOfSync. Click on refresh, and a few of them become in Sync. (Also a bug here)

If you inspect the diff, you should see only this:
image

Now go to App Details -> Manifest and click EDIT. Right in the end, paste this:

ignoreDifferences:
  - group: apiextensions.k8s.io
    kind: CustomResourceDefinition
    jsonPointers:
      - /spec/names/shortNames

Hit Save, close it and sync.
The application will still be OutOfSync.
Clicking refresh will make mark it as synced.

Expected behavior

After setting ignoreDifferences I'd expect the refresh to be automatic.

Screenshots
Screen Recording 2023-02-24 at 3 02 19 PM (1)

Version
Please note the version below seems incorrect. See screenshot:
image

argocd version
argocd: v2.6.2+6e02f8b.dirty
  BuildDate: 2023-02-16T18:43:27Z
  GitCommit: 6e02f8b23201b0620a4ff1bce5d38229ba1eb02e
  GitTreeState: dirty
  GoVersion: go1.19.6
  Compiler: gc
  Platform: darwin/arm64
argocd-server: v2.6.2+6e02f8b.dirty
  BuildDate: 2023-02-16T18:43:27Z
  GitCommit: 6e02f8b23201b0620a4ff1bce5d38229ba1eb02e
  GitTreeState: dirty
  GoVersion: go1.19.6
  Compiler: gc
  Platform: darwin/arm64
  Kustomize Version: v4.5.7 2022-08-02T16:28:01Z
  Helm Version: v3.10.0+gce66412
  Kubectl Version: v0.24.2
  Jsonnet Version: v0.19.1

Logs

Paste any relevant application logs here.
@rufreakde
Copy link

Encountering the same issue with argocd version 2.3.17. It seems the CRDs get changed when applied because of the empty list and hence are never in sync.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants