Skip to content
Tutorials Center
My learning

Topics

Lesson 4 of 37 ยท Getting Started

The Argo CD UI and CLI: A Practical Tour

Tour the Argo CD web interface and the argocd command line: applications list, resource tree, diff, sync, history and rollback, plus the most useful commands and flags.

You can do everything in Argo CD from three places: the web UI, the argocd CLI and the Kubernetes API (the Application objects). The UI is best for seeing; the CLI is best for scripting and quick actions; the YAML in Git is where the real configuration should live. This lesson tours the first two so later lessons can use them freely.

No cluster is available on this site, so the commands are read-only and no real output is shown. The runnable code is a stand-in: a formatter and a command builder that mimic the shape of the CLI, not Argo CD itself.

The web UI

After logging in you land on Applications. Each application appears as a card (or a row in list view) with:

  • its name, project, source repository and target revision,
  • the sync status (Synced, OutOfSync, Unknown) and health status (Healthy, Progressing, Degraded, Suspended, Missing),
  • quick buttons: Sync, Refresh and Delete.

Click an application to open its resource tree: a graph with the Application at the left, then Deployments, ReplicaSets, Pods, Services, Ingresses and so on. Each node has its own health icon, and a yellow icon marks something out of sync. Useful views:

  • Details shows source, destination, sync policy and labels.
  • Diff shows desired against live, with an option to compact it.
  • Events and Logs (per pod) save a trip to kubectl for quick debugging.
  • History and rollback lists past syncs by revision.
  • Pods view / Network view / List view show the same resources from different angles.

The left menu also has Settings: repositories, clusters, projects, certificates, GPG keys and accounts. Most of these can also be created from YAML, which is better for reproducibility.

Logging in on the CLI

Terminal
argocd login localhost:8080 --username admin --insecure
argocd version
argocd context          # list saved server contexts

argocd login --sso opens a browser for single sign-on once it is configured. Contexts are stored in ~/.config/argocd/config; tokens expire, so scripts normally use an API token from a dedicated account (covered under security later).

The commands you will use every day

Terminal
argocd app list                              # all applications with sync and health
argocd app get guestbook                     # details and the resource tree as text
argocd app get guestbook --refresh           # re-fetch from Git first
argocd app diff guestbook                    # desired vs live, like git diff
argocd app sync guestbook                    # apply desired state
argocd app sync guestbook --dry-run          # show what would be applied
argocd app history guestbook                 # list sync history with revisions
argocd app rollback guestbook 3              # roll back to history ID 3
argocd app wait guestbook --health           # block until healthy (good for CI)
argocd app delete guestbook                  # remove the Application

Output formats help scripts: -o json, -o yaml, -o name, -o wide. Selectors filter many apps at once, for example argocd app list -l team=payments or argocd app sync -l tier=frontend.

Other resource families follow the same pattern: argocd repo add|list|rm, argocd cluster add|list|rm, argocd proj create|add-source|add-destination, argocd account list|update-password|generate-token, and argocd admin ... for operator tasks that talk straight to Kubernetes.

Creating an application imperatively looks like this (the YAML way, shown in the next lessons, is usually better):

Terminal
argocd app create guestbook \
  --repo https://github.com/example/gitops-demo.git \
  --path apps/guestbook \
  --dest-server https://kubernetes.default.svc \
  --dest-namespace guestbook

Treat argocd app create and argocd app set as a way to explore. For anything that matters, commit an Application manifest to Git instead, so the Application definition itself has history and review.

Stand-in: format an application list

Real argocd app list prints an aligned table. This stand-in builds a similar table from data so you can practice reading statuses. The data is made up.

JS Stand-in: app list table

Press Run (or Ctrl + Enter) to see the console output here.

No output.

Stand-in: build a command

The second stand-in assembles an argocd app create command from a few fields and warns about common mistakes, such as forgetting the namespace.

JS Stand-in: command builder

Press Run (or Ctrl + Enter) to see the console output here.

No output.

Tips for working fast

  • Press / in the UI to focus the search box; use the filters on the left to see only OutOfSync or Degraded apps.
  • Use argocd app get <name> -o yaml to see the full Application including status.
  • Add --grpc-web to the CLI when your ingress does not support HTTP/2 end to end.
  • The CLI needs network access to argocd-server. For automation inside the cluster, argocd --core talks to Kubernetes directly using your kubeconfig.

Check your understanding

Quick check ยท 4 questions

of 4 answered You scored / 4 ยท perfect!

  1. 1. Which CLI command shows what would change without applying anything?

    --dry-run previews a sync. argocd app diff shows the differences as well.
  2. 2. What does a yellow icon on a node in the resource tree usually mean?

    The tree marks out-of-sync resources so you can see exactly which ones differ.
  3. 3. Why prefer committing an Application manifest over using argocd app create?

    A manifest in Git makes the Application definition itself part of GitOps.
  4. 4. Which flag prints machine-readable output for scripts?

    -o json (or yaml, name, wide) controls the output format.

Summary

  • The UI is for seeing (resource tree, diff, events); the CLI is for scripting; Git is for truth.
  • argocd app list|get|diff|sync|history|rollback|wait|delete cover daily work.
  • Use -o json and label selectors (-l key=value) for automation.
  • Create imperative apps only to learn; commit Application YAML for real work.

Next: Your First Application