What I want is to have ArgoCD approve a job that is in the approval step in CircleCI when a deployment was successful.
However, this has been a multi week journey with no results. I first looked at this:
https://argo-cd.readthedocs.io/en/stable/user-guide/resource_hooks/
I spent the time building out an entire argo workflow, and job. Then setup a pipeline to capture the waiting job id (before updating the yaml file) and run the workflow with that id that would generate a PostSync
that could use that id to approve the waiting circleci job only AFTER a successful deploy, then destroy itself. I also had one for SyncFail as well. My hopes were dashed when I realized this was generic. I couldn't see a way to only run this job for a specific application in argocd, it appears to run on ANY sync event. (What??)
Now I'm looking at this: https://argo-cd.readthedocs.io/en/stable/operator-manual/notifications/
However, yet again I see hiccups already before I event started. There seems no possible way to run custom code, therefore I can't run the API to approve my job. Has anyone gotten a callback system for a specific app working? I can try and hack something together by calling back to a pipeline to run an API, but that just seems dumb. There has to be a better way....