Skip to content

Support getting lineage for ArgoCD Applications #18

@anandf

Description

@anandf

This is a wonderful and promising tool.

I have seen a note that currently it does not support ArgoCD Applications. When I tried running on it, I could just see the events generated by these applications instead of the actual child objects. I would like to enhance this tool to add support for ArgoCD applications as well.

argocd app create guestbook --core --repo https://github.com/anandf/argocd-example-apps.git --path kustomize-guestbook --dest-namespace guestbook --dest-server https://kubernetes.default.svc --sync-policy automated --self-heal --sync-option CreateNamespace=true
application 'guestbook' created
argocd app list --core
NAME              CLUSTER                         NAMESPACE  PROJECT  STATUS  HEALTH       SYNCPOLICY  CONDITIONS  REPO                                               PATH                 TARGET
argocd/guestbook  https://kubernetes.default.svc  guestbook  default  Synced  Progressing  Auto        <none>      https://github.com/anandf/argocd-example-apps.git  kustomize-guestbook

On running lineage command, I get this output

 k lineage application guestbook
NAME                                   READY   STATUS                                                                                     AGE
Application/guestbook                  -                                                                                                  26s
├── Event/guestbook.17f5a5a5b1bdf768   -       ResourceCreated: Unknown user created application                                          26s
├── Event/guestbook.17f5a5a5fa724984   -       OperationStarted: Initiated automated sync to 'd7927a27b4533926b7d86b5f249cd9ebe7625e90'   25s
├── Event/guestbook.17f5a5a5fa90d1f4   -       ResourceUpdated: Updated sync status:  -> OutOfSync                                        25s
├── Event/guestbook.17f5a5a5fabf4424   -       ResourceUpdated: Updated health status:  -> Missing                                        25s
├── Event/guestbook.17f5a5a67f31db2d   -       ResourceUpdated: Updated sync status: OutOfSync -> Synced                                  23s
├── Event/guestbook.17f5a5a67f483a16   -       OperationCompleted: Sync operation to d7927a27b4533926b7d86b5f249cd9ebe7625e90 succeeded   23s
└── Event/guestbook.17f5a5a67f551fb2   -       ResourceUpdated: Updated health status: Missing -> Progressing                             23s

Expected Output

|- Namespace/guestbook   -                8m45s
|- Deployment/kustomize-guestbook-ui                                           0/1                                                                                                                 5m44s
 └── ReplicaSet/kustomize-guestbook-ui-9b9c89b69                             0/1                                                                                                                 5m44s
    └── Pod/kustomize-guestbook-ui-9b9c89b69-qnr66                          0/1     ContainerCreating                                                                                           5m44s                                                                                                        5m44s
|- Service/kustomize-guestbook-ui                   -                7m36s
└── EndpointSlice/kustomize-guestbook-ui-b5xbb   -                7m36s

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions