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

Enable to ignore manifests' fields from drift detection #4190

Closed
khanhtc1202 opened this issue Feb 15, 2023 · 8 comments
Closed

Enable to ignore manifests' fields from drift detection #4190

khanhtc1202 opened this issue Feb 15, 2023 · 8 comments
Assignees
Labels
kind/enhancement New feature or request Stale

Comments

@khanhtc1202
Copy link
Member

What would you like to be added:

Why is this needed:

Some autogenerated fields in k8s manifests changed on each rerun, thus users want to ignore them from the drift detection feature. Would be best if we can make it available via application config.

@khanhtc1202 khanhtc1202 added the kind/enhancement New feature or request label Feb 15, 2023
@golemiso
Copy link
Contributor

How about definining a new annotation pipecd.dev/ignore-drift-detection-on?

spec:
  template:
    metadata:
      annotations:
        deployedAt: {{ now | unixEpoch | quote }} # regenerate every run
        pipecd.dev/ignore-drift-detection-on: |
          ["spec.template.metadata.annotations.deployedAt"]

@khanhtc1202
Copy link
Member Author

Thanks for the idea, but we think that this feature should be portable to other application kinds which pipecd currently supports, so maybe it's better to make this configuration a part of the pipecd application configuration (the app.pipecd.yaml file). wdyt? 🤔

@golemiso
Copy link
Contributor

golemiso commented Feb 17, 2023

It could be more complicated when you specify fields out of the resource. You have to specify the resource name, kind and apiVersion since you can have several resources on one deployment.

@funera1
Copy link
Member

funera1 commented Feb 22, 2023

TODO

  • Support Kubernetes
  • Support Cloud Run
  • Support Lambda
  • Support ECS
  • Documentation

I don't think terraform's drift detection is necessary for this issue because it doesn't detect it in the manifest diff, so I won't support it for now.

@funera1
Copy link
Member

funera1 commented Feb 22, 2023

ECS and Lambda have not yet implemented drift detection, so I will separate them into separate Issues.

@funera1
Copy link
Member

funera1 commented Mar 7, 2023

By operating Kubernetes' ignoreManifests, and if it looks OK, I will implement CloudRun's.

Copy link
Contributor

This issue is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be closed in 7 days.

@github-actions github-actions bot added the Stale label Nov 15, 2023
Copy link
Contributor

This issue was closed because it has been stalled for 7 days with no activity. Feel free to reopen if still applicable.

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Nov 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement New feature or request Stale
Projects
None yet
Development

No branches or pull requests

3 participants