Argo CD Hour 8 (optional): 50 production issues + 50 interview questions

Turn the first seven lessons into two skills: when you see a Condition on the Argo CD UI, a failed Sync, or an app that is permanently OutOfSync, know which stage of the reconciliation chain it belongs to — Repo Server rendering, Controller comparison, Sync execution, health assessment, project and RBAC validation — and which first diagnostic command to run; in an interview, explain GitOps pull-based reconciliation in two minutes and lead a GitOps incident post-mortem
A: 50 production issuesB: 50 interview questionsArgo CD v3.6.1Verified 2026-11-17
Overall learning objectives
  • When you see a raw error message (unable to resolve 'mian' to a commit SHA,app path does not exist,do not match any of the allowed destinations in project,metadata.annotations: Too long,waiting for completion of hook,another operation is already in progress,contains applications with duplicate name,permission denied: applications, sync, …,no key could decrypt secret,Manifest generation error (cached)…) lets you tell which of these categories it belongs to: Install/repo/Application, sync/diff/health, ApplicationSet/multi-cluster/permissions, secrets/delivery/performance/upgrade— and name the first diagnostic command.
  • Understand the mechanisms: how Repo Server fetches Git and renders (Helm only does helm template), how the Controller compares three-way and server-side diffs using the cluster cache, Sync's phase → wave → kind ordering and hooks, health rules (an Ingress or LoadBalancer with no address is Progressing), AppProject validation of source / destination / resource kinds, Casbin RBAC decisions, ApplicationSet generator expansion into Applications, and sharding and caching.
  • Be able to work on a kind cluster lab (plus a second cluster lab2) and your gitops-lab repository's lab8 branch, reproduce, diagnose, fix and clean up more than 40 of these issues without affecting the main branch's podinfo application.
  • Be able to answer, using the structure “30-second answer → mechanism → config / commands → production experience”, the 50 Senior Cloud / DevOps / Platform Engineer interview questions, 12 of which are GitOps platform design and incident post-mortems scenario questions (ApplicationSet accidentally deleting production, prune deleting a PVC, a secret committed to Git, controller OOM after an upgrade…).
  • Use mock interviews (timed, self-assessed) to measure your mastery rate and identify weak modules.

1-hour time allocation table

#TimeModuleCore contentAnimation · interactiveLab
0Pre-classInstructions and fault lab environmentConfirm kind cluster lab with Argo CD v3.6; in gitops-lab create lab8 branch and lab8/ directory; generate helper scripts lab8.sh; create lab project lab8Environment self-checkGenerate lab8.sh
100–08A · Install, repos and ApplicationIssues 1–12: CLI certificates and gRPC, initial password, Ingress redirect loop, repo authentication, known_hosts, private CA,to a commit SHA,app path does not exist, Helm values files and multi-source $values, destination not in project, source repo not in project,existing application spec is different“Application won't start” troubleshooting decision treeRevision · path · project boundary
208–16A · Sync, diff and healthIssues 13–25: permanent OutOfSync caused by HPA / webhooks, default-value normalization diffs, annotations too long, CRD does not exist, namespace does not exist, namespace missing, hook stuck, operation in progress, Progressing never ends, progress deadline exceeded, not pruned, shared resources, deletion stuckSync execution simulator (phase / wave / hooks / health)Drift · hooks · health · finalizer
316–24A · ApplicationSet, multi-cluster and permissionsIssues 26–38: duplicate names, missing template keys, cascade deletion when deleting an AppSet, Git generator delay, project does not exist, cluster name does not exist, kind's 127.0.0.1, RBAC denial, SSO group not taking effect, v3 log permissions, v3 fine-grained permissions, cluster-scoped resources not on the allowlist, Applications in any namespaceRBAC decision simulatorAppSet · lab2 · RBAC
424–30A · Secrets, delivery, performance and upgradesIssues 39–50: Sealed Secrets cannot decrypt / already exists, ESO sync failure, CMP cannot find plugin, render timeout and cached errors, sync windows, Rollouts paused and aborted, Image Updater not updating, notifications not sent, controller OOM and slowness, Git polling and rate limiting, CRDs and tracking methods when upgrading to v3 / 3.3+“Slow / not updating / abnormal after upgrade” troubleshooting decision treeSecrets · sync windows · render timeout
530–37B · GitOps and architectureInterview 1–13Mock interview2 scenario questions
637–44B · Application and syncInterview 14–25Mock interview2 scenario questions
744–52B · Scale, multi-tenancy and securityInterview 26–38Mock interview3 scenario questions
852–60B · Scenario design and incident post-mortemsInterview 39–50 (including 6 incident post-mortem questions)Mock interview3 scenario questions
—Post-classCheat sheet · Comprehensive practice50 “error → first command → fix” entries; 50 flash cards; 8 mixed faults; full mock interviewFull mock interviewCourse exam: 12 questions

Knowledge coverage matrix

Topicm1m2m3m4m5m6m7m8
Architecture and reconciliation loop (Repo Server / Controller / Redis / API Server)●●—●●●●●
Repositories, credentials, manifest sources (Kustomize / Helm / multi-source / CMP)●——●●●●—
Sync: options, wave, hooks, prune, selfHeal, SSA—●●●—●—●
Diff and health: ignoreDifferences, Server-Side Diff, Lua health—●—●●●—●
App of Apps, ApplicationSet, generators and progressive sync——●———●●
Multi-cluster, AppProject, RBAC, SSO●—●—●—●●
Secrets management (Sealed Secrets / ESO / SOPS) and supply chain———●●—●●
Progressive delivery (Rollouts, Image Updater, notifications, sync windows, promotion)———●—●—●
Performance, sharding, monitoring, high availability———●●—●●
Upgrades (v2 → v3, 3.3 CRDs, 3.5 Helm 4), disaster recovery and post-mortems●—●●●●●●

Topics this course does not cover (where to learn them)

  • System-level coverage of each topic: GitOps principles, architecture, installation, state model → Lesson 1; manifest sources, multi-source, sync options, waves and hooks, health, ignoreDifferences, tracking methods → Lesson 2; App of Apps, ApplicationSet, generators, RollingSync → Lesson 3; AppProject, RBAC, SSO, multi-cluster, any namespace → Lesson 4; security hardening, repo credentials, Sealed Secrets, ESO, SOPS + CMP, Source Integrity → Lesson 5; CI changing Git, Rollouts, AnalysisTemplate, Image Updater, notifications, sync windows, promotion → Lesson 6; high availability, sharding, Repo Server, monitoring, OutOfSync loops, stuck deletion, upgrades and disaster recovery → Lesson 7. This lesson only covers “what to do when something goes wrong” and “how to answer in an interview.”
  • Failures in Kubernetes itself (Pod CrashLoopBackOff, scheduling, PVC, networking) → Kubernetes 8 hours; template errors in the Helm chart itself → Helm 8 hours(its Lesson 5 has an introduction to Argo CD / Flux); how CI changes Git → GitHub 8 hours,GitLab 8 hours; AKS GitOps extension and Workload Identity → AKS 8 hours; dashboards and alerts for Argo CD metrics → Prometheus & Grafana 8 hours.

How to use this lesson

When troubleshooting (Part A)
  • Open the Quick view, paste the most distinctive words from the Condition or Sync message (such as commit SHA,allowed destinations,Too long,hook,duplicate,permission denied,decrypt,cached) into the filter box.
  • Click a table row to jump straight to Issue details, and follow “diagnose → compare output → fix.”
  • No error, just “not moving / spinning forever / slow”? Use the Animation decision tree or simulator tabs to locate it.
Before the interview (Part B)
  • First look at the Quick view, and pick out the questions you are unsure of by difficulty.
  • Mock interview: random questions, 2-minute countdown, answer first and then check, self-rate “answered / partial / don't know”; scores are saved in this browser.
  • Answer structure: one-sentence conclusion → mechanism → configuration / commands → pitfalls I've hit; post-mortem questions follow “timeline → impact → root cause (5 Whys) → mitigation → long-term improvement → metrics.”
Post-class
  • Cheat sheet Suitable for printing and posting at your desk or adding to the on-call handbook.
  • Comprehensive practice: 8 mixed faults + full mock interview (pick 10 of 50) + course exam.
  • Each question links back to the relevant module in Lessons 1–7 for review.

Entry structure of Parts A / B

Part A · 50 production issues

Symptom → raw error / status condition → root cause (at the mechanism level) → diagnostic command (argocd CLI and kubectl) → sample expected output → fix → prevention and best practices → reproduction lab (gitops-lab of the lab8 branch) → see Lesson N. Raw error messages are labeled with three sources:Source-verified means checked character by character against the format strings in the Argo CD v3.6.1 source (argoproj/argo-cd tag v3.6.1, including the already-merged gitops-engine/); variable parts (names, URLs, times) are examples;Official docs means quoted from argo-cd.readthedocs.io or related project docs / source (Sealed Secrets v0.41.2, ESO v2.15.0);Check against actual output means the outer wrapper from Git, gRPC, the Go standard library or the Kubernetes API; prefixes and wording vary by version and transport (git CLI / go-git, gRPC / gRPC-Web).

Part B · 50 interview questions

Question → 30-second answer → in-depth answer (principles, YAML / commands) → common follow-ups → bonus points → common wrong answers. Difficulty:BeginnerIntermediateAdvanced. Target roles: Senior Cloud / DevOps / Platform Engineer. Module 8 contains 6 incident post-mortem questions (Q41, Q42, Q43, Q44, Q48, Q50) and 6 platform design questions.

Relationship to the first seven lessons

CourseMost-referenced content in this lesson
Lesson 1: GitOps and Argo CD core · Lesson 2: Application in depthreconciliation loop (Repo Server rendering → Controller comparison → Sync / Health → writing status back), refresh and hard refresh, self-heal and prune; manifest sources, multi-source $values, sync options (ServerSideApply, CreateNamespace, Replace, PruneLast), Sync Waves and hooks, Lua health checks, ignoreDifferences, annotation tracking
Lesson 3: App of Apps and ApplicationSet · Lesson 4: Multi-cluster and multi-tenancygenerators, goTemplate,applicationsSync policies,preserveResourcesOnDeletion, RollingSync; AppProject sources / destinations / allowlists,policy.csv, project roles and tokens, Dex / OIDC, declarative cluster Secrets,lab2 registration,application.namespaces
Lesson 5: Security and secrets · Lesson 6: Progressive delivery · Lesson 7: Scale and troubleshootingcredential templates, Sealed Secrets, ESO, SOPS + CMP sidecar; Rollouts, Image Updater (v1.x's ImageUpdater CR), Notifications, sync windows; sharding, processor counts, Repo Server cache and timeouts, metrics, deletion and finalizers, upgrades and argocd admin export
Version notes This lesson uses Argo CD v3.6.1 (released 2026-11-04; Helm chart argo/argo-cd 10.18.0, appVersion v3.6.1,kubeVersion >=1.25.0-0) as its baseline; the Kubernetes versions officially tested for 3.6 are v1.37, v1.36, v1.35 and v1.34, and kind v0.33.0's default node image is kindest/node:v1.37.0. Version changes directly related to this lesson's issues: v3.0 default annotation tracking, enforced log RBAC,update/delete no longer inherited by child resources; removed argocd-cm in the old-style repository configuration, ignored by default status fields and updates in ignoreDifferences; 3.3 the ApplicationSet CRD exceeds the annotation limit for client-side apply, so an upgrade with server-side apply is required; 3.5 built-in Helm upgraded to 4.2.0, and GnuPG verification replaced by Source Integrity; 3.6 enabling ServerSideApply=true applications switch to Server-Side Diff. Adjacent tools (verified 2026-11-17): Argo Rollouts v1.10.2, Argo CD Image Updater v1.5.0, Sealed Secrets v0.41.2, External Secrets Operator v2.15.0, Kargo v1.12.6, podinfo 6.17.0.

Module 0 · Instructions and fault lab environment

Pre-class · reuse the kind cluster lab (from Lesson 4 onward there is also lab2), namespaces argocd Argo CD and the gitops-lab repository; all faults are placed in separate lab8 branch,lab8 project and lab8-* namespaces
Pre-class: 10 minutesLocal and free
Module objectives
  • Confirm the Argo CD version and component health, and log in to the CLI.
  • In gitops-lab create a lab8 branch, with the fault list in lab8/pbNN-*/; create an AppProject that only allows lab8-* namespace lab8, so the experiments will not touch podinfo-* production applications.
  • Generate helper scripts lab8.sh: one-command creation of fault Applications, viewing Conditions and operation status, collecting component logs, and cleanup.

Prerequisites

  • Complete Lesson 1 Module 0: a kind cluster lab (context kind-lab), with Argo CD installed from the official chart argo/argo-cd in the argocd namespace (release name argocd, values file ~/gitops-lab/bootstrap/argocd-values.yaml) kubectl -n argocd port-forward svc/argocd-server 8080:443 after argocd login localhost:8080 --insecure.
  • Your own GitHub repository gitops-lab (example https://github.com/<you>/gitops-lab, local clone ~/gitops-lab, default branch main), which contains apps/podinfo/base and overlays/dev|staging|prod.
  • The multi-cluster issues in Module 3 need a second kind cluster lab2 (created in Lesson 4; Argo CD cluster name lab2); the secrets issues in Module 4 need the Sealed Secrets controller installed in Lesson 5 (ESO optional). Without them, read these issues only, or install the minimal starting point given at the beginning of each lab.
  • If you do not have the outcomes from the previous lesson, the minimal starting point is as follows (about 5 minutes):
kind create cluster --name lab                                   # kind v0.33.0 default kindest/node:v1.37.0
helm repo add argo https://argoproj.github.io/argo-helm && helm repo update
helm upgrade --install argocd argo/argo-cd -n argocd --create-namespace --version 10.18.0
kubectl -n argocd rollout status deploy/argocd-server
kubectl -n argocd port-forward svc/argocd-server 8080:443 &
argocd login localhost:8080 --username admin --insecure \
  --password "$(kubectl -n argocd get secret argocd-initial-admin-secret -o jsonpath='{.data.password}' | base64 -d)"
argocd account update-password --current-password "$(kubectl -n argocd get secret argocd-initial-admin-secret -o jsonpath='{.data.password}' | base64 -d)" \
  --new-password 'Lab-Argo-2026!'                 # Lab password matching Lesson 1 (local lab only)
export ADMIN_PASS='Lab-Argo-2026!' P='Lab-Argo-2026!'

Outcomes from Lesson 1 also include the values file ~/gitops-lab/bootstrap/argocd-values.yaml (later used to helm upgrade argocd argo/argo-cd -n argocd --version 10.18.0 -f … modify the configuration), Application podinfo-dev (project default,automated + prune + selfHeal, with resources-finalizer.argocd.argoproj.io). The lab in this lesson uses $ADMIN_PASS / $P all refer to the lab password Lab-Argo-2026!.

Step 1: environment self-check

kubectl config current-context
argocd version --short 2>/dev/null || argocd version
kubectl -n argocd get pods
argocd app list -o name
kind-lab
argocd: v3.6.1+94037c4
argocd-server: v3.6.1+94037c4
NAME                                                READY   STATUS    RESTARTS   AGE
argocd-application-controller-0                     1/1     Running   0          2d
argocd-applicationset-controller-7c9d…              1/1     Running   0          2d
argocd-dex-server-6b8f…                             1/1     Running   0          2d
argocd-notifications-controller-5d7c…               1/1     Running   0          2d
argocd-redis-6f9b…                                  1/1     Running   0          2d
argocd-repo-server-84c6…                            1/1     Running   0          2d
argocd-server-7f6d…                                 1/1     Running   0          2d
argocd/podinfo-dev
(plus other applications created in Lessons 2–7, such as podinfo-staging, podinfo-prod, root)

Note argocd-application-controller is StatefulSet (sharding assigns clusters by ordinal); the rest are Deployments. The CLI and server should stay on the same minor version.

Step 2: lab8 branch, project and helper scripts

cd ~/gitops-lab && git switch -c lab8 && mkdir -p lab8 && git commit --allow-empty -m "lab8: start" && git push -u origin lab8
kubectl apply -f - <<'EOF'
apiVersion: argoproj.io/v1alpha1
kind: AppProject
metadata: {name: lab8, namespace: argocd}
spec:
  description: Hour-8 fault lab - only lab8-* namespaces
  sourceRepos: ['https://github.com/<you>/gitops-lab']
  destinations:
  - {server: https://kubernetes.default.svc, namespace: 'lab8-*'}
  clusterResourceWhitelist: []          # by default no cluster-scoped resources are allowed (used by issue #37)
EOF
cat > ~/gitops-lab/lab8/lab8.sh <<'EOF'
# Usage: source ~/gitops-lab/lab8/lab8.sh
L8_REPO=${L8_REPO:-https://github.com/<you>/gitops-lab}
# Create a fault Application pointing to a directory of the lab8 branch: l8_app pb08 lab8/pb08-path [extra argocd arguments…]
l8_app() { local n=$1 p=$2; shift 2
  argocd app create "lab8-$n" --project lab8 --repo "$L8_REPO" --revision lab8 --path "$p" \
    --dest-server https://kubernetes.default.svc --dest-namespace "lab8-$n" --label lab8=true --upsert "$@"; }
# View Conditions, Sync/Health and the latest operation
l8_why() { argocd app get "lab8-$1" --show-operation | sed -n '1,40p'
  kubectl -n argocd get application "lab8-$1" -o jsonpath='{range .status.conditions[*]}{.type}{": "}{.message}{"\n"}{end}'; }
# Component logs (default controller): l8_logs repo-server 50
l8_logs() { local c=${1:-application-controller} n=${2:-80}
  if [ "$c" = application-controller ]; then kubectl -n argocd logs sts/argocd-application-controller --tail="$n"
  else kubectl -n argocd logs deploy/argocd-"$c" --tail="$n"; fi; }
# Clean up all lab8 applications (non-cascading; argocd removes the finalizer first) and the namespace
l8_clean() { argocd app list -l lab8=true -o name | xargs -r -n1 argocd app delete --yes --wait
  kubectl get ns -o name | grep '^namespace/lab8-' | xargs -r kubectl delete --wait=false; }
EOF
source ~/gitops-lab/lab8/lab8.sh && type l8_app | head -1
l8_app is a function

lab8.sh itself does not need to be committed to Git (it is not an object rendered by Argo CD); but it can be committed for team sharing, and Argo CD will not treat .sh as a manifest. Each fault directory (for example lab8/pb08-path/) is given in the "reproduction lab" of the corresponding issue; commit it to the lab8 branch, then use l8_app to create the application.

Step 3: naming and safety conventions

ConventionDescription
Application name lab8-pbNN, namespace lab8-pbNNboth carry the label lab8=true; project lab8 only allows lab8-* namespace — this itself demonstrates the project boundary (#10, #37)
Git revision is pinned to lab8 branchDo not create faults on main ; for comparison, use git diff main lab8 -- lab8/
to change Argo CD configuration (argocd-cm,argocd-rbac-cm,argocd-cmd-params-cm) — back up firstkubectl -n argocd get cm argocd-cm argocd-rbac-cm argocd-cmd-params-cm -o yaml > ~/lab8-cm-backup.yaml; in production these should all be managed by Helm values / Git; after the lab, use helm upgrade to restore
(auto-sync disabled by default)Fault applications are manually synced by default so you can watch each step; issues that need auto-sync (#13, #23, #50) are explained separately

Connection to the previous lesson

  • The troubleshooting order from Lesson 7 is reused in full: Condition (status.conditions) → operation status (status.operationState) → resource tree (argocd app resources,argocd app get) → diff (argocd app diff) → component logs (repo-server handles rendering, application-controller handles comparison and sync, server handles the API and RBAC, applicationset-controller handles generation).
  • “Who reported the error” decides where to look for logs: render errors (ComparisonError,Manifest generation error) → repo-server; sync errors (one or more objects failed to apply) → controller + target cluster API; denials (permission denied) → server; AppSet Condition → applicationset-controller.

Lab safety rules

Do not run this lesson's labs on a production Argo CD Several issues in this lesson demonstrate “deleting the wrong thing” (#25 deletion stuck, #28 deleting an ApplicationSet, #23 prune) and “changing global configuration” (#33–#36 RBAC, #48 processor count). Only do these on the kind cluster; back up ConfigMaps before changing them; do not lab8 relax the project's destination to *.
source ~/gitops-lab/lab8/lab8.sh && l8_clean
kubectl -n argocd delete appproject lab8 --ignore-not-found
kubectl apply -f ~/lab8-cm-backup.yaml          # restore configuration (or helm upgrade argocd argo/argo-cd -n argocd -f ~/gitops-lab/bootstrap/argocd-values.yaml)
cd ~/gitops-lab && git switch main               # the lab8 branch can be kept for review, or git push origin --delete lab8

Self-check list

Module 1 · Part A: Install, repos and Application (issues 1–12)

00:00 – 08:00 · CLI login and TLS, initial password, Ingress and gRPC-Web, repo credentials and known_hosts, private CA, revision resolution, paths, Helm values and multi-source, AppProject sources and destinations, declarative vs imperative conflicts
8 minlogin → repo → render → validate12 issues
Learning objectives
  • Split “Application won't start” into four stages: Access Argo CD (CLI / UI / TLS / gRPC) → Access Git (credentials, known_hosts, CA) → Render (revision, path, Helm values, multi-source) → Validate (AppProject's sourceRepos and destinations). Errors from each stage appear in different places: CLI terminal,argocd repo list 's connection status,ComparisonError Condition,InvalidSpecError Condition.
  • Know that rendering happens in Repo Server: it clones the repo, resolves the revision, runs Kustomize / helm template / CMP, and caches the result in Redis; the message prefix for render failures is Failed to load target state: failed to generate manifest for source 1 of 1: ….
  • Be able to use argocd repo get,argocd app get --hard-refresh,argocd app manifests,argocd proj get and repo-server logs to pinpoint the specific cause within 2 minutes.

Enter keywords from the error or symptom (such as x509,redirect,authentication,knownhosts,commit SHA,app path,values,allowed destinations,not permitted,upsert) to filter; click a row to jump to the matching entry in “Issue details.”

#1 argocd login: x509: certificate signed by unknown authority / CLI command hangs or reports a gRPC error after logging in through Ingress
$ argocd login localhost:8080
FATA[0000] rpc error: code = Unavailable desc = connection error: desc = "transport: authentication handshake failed: tls: failed to verify certificate: x509: certificate signed by unknown authority"

Check against actual output the wording comes from Go's crypto/tls and gRPC; varies slightly by Go version.

Symptom: A freshly installed Argo CD: the UI opens after “continue to site” in the browser, but CLI login fails; or after exposure through an Ingress (which only forwards HTTP/1.1),argocd login succeeds but argocd app list hangs or reports a protocol error.

Root cause: argocd-server uses a default self-signed certificate (generated by argocd-secret , or provided with argocd-server-tls Secret), and the CLI verifies certificates by default. The CLI uses native gRPC (HTTP/2); many Ingresses and load balancers only support HTTP/1.1, so you need --grpc-web to let the CLI communicate over HTTP/1.1 via gRPC-Web.

Diagnostic commands
openssl s_client -connect localhost:8080 -servername localhost </dev/null 2>/dev/null | openssl x509 -noout -subject -issuer -dates
kubectl -n argocd get secret argocd-server-tls 2>&1 | head -2      # if present, prefer its certificate
argocd login argocd.example.com --grpc-web --loglevel debug          # compare gRPC and gRPC-Web
subject=O = Argo CD
issuer=O = Argo CD
Error from server (NotFound): secrets "argocd-server-tls" not found
Fix
argocd login localhost:8080 --insecure                    # lab only: skip certificate verification
argocd login argocd.example.com --grpc-web                # when going through an HTTP/1.1 Ingress
# Production: issue a certificate with cert-manager and place it in argocd-server-tls, or terminate TLS at the Ingress and run the server in insecure mode (#3)
Prevention and best practices
  • Standardize the production entry point: one domain with a trusted certificate; the CLI and automation use the same domain, and record it in ~/.config/argocd/config the team's docs grpc-web: true.
  • Automation (CI) should not use admin account and --insecure: use a project token or the API key of a local account, and access through a trusted certificate.
Reproduction lab
argocd logout localhost:8080; argocd login localhost:8080 --username admin --password "$P"; echo "exit=$?"   # observe x509
argocd login localhost:8080 --username admin --password "$P" --insecure

See also Lesson 1 Module 3 Installation and CLI login,Lesson 5 Module 1 Security hardening.

#2 Error from server (NotFound): secrets "argocd-initial-admin-secret" not found (the initial password is gone)
$ kubectl -n argocd get secret argocd-initial-admin-secret -o jsonpath='{.data.password}'
Error from server (NotFound): secrets "argocd-initial-admin-secret" not found

Official docs FAQ: since v1.9 the initial password is in argocd-initial-admin-secret ; to change the password, update argocd-secret of admin.password (bcrypt hash).

Symptom: A colleague followed the getting-started guide's advice to “delete the initial Secret after changing the password”; or Argo CD is self-managed by GitOps and the initial Secret was pruned because it is not in Git; a new team member cannot get the admin password.

Root cause: The initial Secret is only a “plaintext copy for first login”; what actually takes effect is argocd-secret in admin.password (bcrypt) and admin.passwordMtime. Deleting the initial Secret does not affect login; it only loses the plaintext.

Diagnostic commands
kubectl -n argocd get secret argocd-secret -o jsonpath='{.data}' | jq 'keys'
argocd admin initial-password -n argocd          # read the initial password (while the Secret exists)
kubectl -n argocd get cm argocd-cm -o jsonpath='{.data.admin\.enabled}'
Fix
HASH=$(argocd account bcrypt --password 'N3w-Strong-Pass!')
kubectl -n argocd patch secret argocd-secret -p "{\"stringData\":{\"admin.password\":\"$HASH\",\"admin.passwordMtime\":\"$(date -u +%FT%TZ)\"}}"
argocd login localhost:8080 --username admin --password 'N3w-Strong-Pass!' --insecure
Prevention and best practices
  • After integrating SSO in production, set admin.enabled: "false" (argocd-cm), keep admin only as a break-glass account stored in the password vault.
  • When self-managing Argo CD, do not put argocd-secret / the initial Secret into the prune scope (the Helm chart manages it by default argocd-secret; note configs.secret.createSecret).

See Lesson 1 Module 3,Lesson 4 Module 4 SSO.

#3 browser ERR_TOO_MANY_REDIRECTS (UI won't open after Ingress terminates TLS)
This page isn't working
argocd.example.com redirected you too many times.
ERR_TOO_MANY_REDIRECTS

Official docs Ingress configuration docs: when the Ingress terminates TLS, the API server should turn TLS off — add --insecure, or in argocd-cmd-params-cm set server.insecure: "true".

Symptom: The Ingress (ingress-nginx, Traefik, cloud LB) terminates HTTPS at the edge and forwards HTTP to port 80 of argocd-server; argocd-server sees an HTTP request and returns a 307 redirect to HTTPS; the browser goes back through the Ingress over HTTP to the backend… an endless loop.

Root cause: Both layers want to “own” TLS. Use either TLS passthrough (the backend terminates TLS) or edge termination with an insecure backend; do not split the work between the two.

Diagnostic commands
curl -skI https://argocd.example.com | sed -n '1,5p'
kubectl -n argocd get cm argocd-cmd-params-cm -o jsonpath='{.data.server\.insecure}'; echo
kubectl -n argocd get ingress -o yaml | grep -E 'backend-protocol|ssl-passthrough|servicePort|number'
HTTP/2 307
location: https://argocd.example.com/
false
Fix
configs:
  params:
    server.insecure: true        # when TLS terminates at the edge
server:
  ingress:
    enabled: true
    hostname: argocd.example.com
    tls: true
helm upgrade argocd argo/argo-cd -n argocd -f ~/gitops-lab/bootstrap/argocd-values.yaml
kubectl -n argocd rollout restart deploy/argocd-server     # params are only read at startup
Prevention and best practices
  • Pick one pattern and document it in the platform docs: SSL passthrough (the CLI can use native gRPC), or edge termination + server.insecure (the CLI uses --grpc-web, or create a separate Ingress for gRPC / use an LB that supports an HTTP/2 backend).
  • argocd-cmd-params-cm changes require restarting the corresponding component — a common reason for “changed but no effect.”

See Lesson 1 Module 3,Lesson 7 Module 1 High-availability deployment.

#4 Unable to connect to repository: … authentication required (private repo / expired token)
TYPE  NAME  REPO                                       INSECURE  OCI    LFS    CREDS  STATUS  MESSAGE
git         https://github.com/<you>/gitops-lab-private  false     false  false  true   Failed  Unable to connect to repository: rpc error: code = Unknown desc = error testing repository connectivity: authentication required

Source-verified Prefix Unable to connect to repository: %v (server/repository/repository.go);depends on actual output authentication required comes from go-git's transport layer; over HTTPS it can also appear as authentication failed or as 403 text.

Symptom: A newly created application reports ComparisonError, or an application that has been running for months suddenly reports Unknown: GitHub fine-grained PAT expired, unauthorized token after SSO enforcement, repo made private, old URL no longer redirects after a rename.

Root cause: Repo Server accesses Git using credentials from a argocd.argoproj.io/secret-type: repository (single repo) or a repo-creds (credential template matched by URL prefix) Secret. The URL must match the one in the Application repoURL exactly (including .git suffix, case,https and ssh forms) to match a single-repo credential; credential templates match by longest prefix.

Diagnostic commands
argocd repo list
argocd repo get https://github.com/<you>/gitops-lab-private --refresh hard
kubectl -n argocd get secret -l argocd.argoproj.io/secret-type -o custom-columns=NAME:.metadata.name,TYPE:.metadata.labels.argocd\.argoproj\.io/secret-type
kubectl -n argocd logs deploy/argocd-repo-server --tail=50 | grep -iE 'auth|denied|403'
Fix
apiVersion: v1
kind: Secret
metadata:
  name: github-org-creds
  namespace: argocd
  labels: {argocd.argoproj.io/secret-type: repo-creds}
stringData:
  type: git
  url: https://github.com/<you>          # prefix
  username: x-access-token
  password: <PAT or GitHub App token>
  # GitHub App is recommended: githubAppID / githubAppInstallationID / githubAppPrivateKey
Prevention and best practices
  • Prefer GitHub App or a deploy key (read-only, single repo) instead of a personal PAT; put token expiry dates on a calendar and monitor the growth of repo-server metrics argocd_git_lsremote_fail_total / argocd_git_fetch_fail_total .
  • Manage the credential Secret itself with Sealed Secrets / ESO (Lesson 5); never put it in Git in plaintext.
  • Since v3.0 no longer supports argocd-cm old-style repositories / repository.credentials configuration; you must migrate to Secrets before upgrading (#50).
Reproduction lab
argocd repo add https://github.com/<you>/gitops-lab-private --username x --password wrong   # observe the failure
argocd repo list

See Lesson 5 Module 2 Repo credentials and credential templates.

#5 ssh: handshake failed: knownhosts: key is unknown (SSH repo)
Unable to connect to repository: rpc error: code = Unknown desc = error testing repository connectivity: ssh: handshake failed: knownhosts: key is unknown

Symptom: Adding a repo with git@github.com:<you>/gitops-lab.git fails; or after the Git server changes its host key (self-hosted GitLab reinstalled or migrated), all applications fail; an intranet Gitea uses a non-22 port.

Root cause: Argo CD performs strict host key verification, known hosts are stored in a ConfigMap argocd-ssh-known-hosts-cm (mounted into repo-server). By default only the keys of a few public hosting platforms are pre-seeded. Since v3.5, even if the repo has no configured credentials, SSH connections will also use known_hosts (upgrade notes: “SSH known_hosts now used for repositories without configured credentials”).

Diagnostic commands
argocd cert list --cert-type ssh
kubectl -n argocd get cm argocd-ssh-known-hosts-cm -o jsonpath='{.data.ssh_known_hosts}' | grep -c .
ssh-keyscan -p 2222 gitea.example.internal 2>/dev/null | head -2
Fix
ssh-keyscan -p 2222 gitea.example.internal | argocd cert add-ssh --batch
# or declaratively: write the ssh-keyscan output into configs.ssh.extraHosts in Helm values
Prevention and best practices
  • Do not use insecure: "true" to skip host verification — that gives up man-in-the-middle protection.
  • Host key rotation (GitHub's 2023 RSA key rotation is a real case) should go through change control: add the new key to known_hosts first, then switch.
  • HTTPS + GitHub App is often easier to operate than SSH (no known_hosts needed).

See Lesson 5 Module 2.

#6 x509: certificate signed by unknown authority (self-hosted Git / Helm / OCI repos using a private CA)
Unable to connect to repository: rpc error: code = Unknown desc = error testing repository connectivity: Get "https://gitlab.corp.local/platform/gitops.git/info/refs?service=git-upload-pack": tls: failed to verify certificate: x509: certificate signed by unknown authority

Symptom: The company intranet GitLab, Harbor (Helm OCI) and Nexus use certificates issued by the enterprise CA; developer machines trust that CA, but Argo CD does not.

Root cause: The repo-server container's system trust store does not contain the enterprise CA. Argo CD's approach is to put the PEM certificate into a ConfigMap argocd-tls-certs-cm (key name is server hostname), mounted into repo-server.

Diagnostic commands
argocd cert list --cert-type https
openssl s_client -connect gitlab.corp.local:443 -showcerts </dev/null 2>/dev/null | grep -E 's:|i:'
Fix
argocd cert add-tls gitlab.corp.local --from ./corp-root-ca.pem
# declarative (Helm values)
#   configs:
#     tls:
#       certificates:
#         gitlab.corp.local: |
#           -----BEGIN CERTIFICATE----- …
Prevention and best practices
  • Configure certificates by “hostname,”different ports and different aliases each need separate configuration; the registry host used for Helm OCI needs it too.
  • Add the new CA ahead of a CA rotation (one ConfigMap can hold several certificates for the same host).
  • Only use this in an isolated lab environment. --insecure-skip-server-verification.

See Lesson 5 Module 2.

#7 ComparisonError: … unable to resolve 'mian' to a commit SHA (branch / tag misspelled or deleted)
CONDITION        MESSAGE
ComparisonError  Failed to load target state: failed to generate manifest for source 1 of 1: rpc error: code = Unknown desc = unable to resolve 'mian' to a commit SHA

Source-verified Failed to load target state: (controller/state.go),failed to generate manifest for source %d of %d: %w,unable to resolve '%s' to a commit SHA (util/git/client.go).

Symptom: A newly created application directly Unknown; or one day a batch of preview-environment applications all start failing — the feature branch was deleted automatically after being merged.

Root cause: Repo Server uses git ls-remote to resolve targetRevision (branch, tag,HEAD or SHA) into a commit SHA; if the reference cannot be found, this error is reported. Common causes: typos, a tag that exists only locally and was never pushed, a deleted branch, or the repo's default branch changing from master to main.

Diagnostic commands
argocd app get lab8-pb07 -o json | jq -r '.spec.source.targetRevision'
git ls-remote https://github.com/<you>/gitops-lab | grep -E 'refs/(heads|tags)/' | head
kubectl -n argocd logs deploy/argocd-repo-server --tail=30 | grep -i 'resolve'
Fix
argocd app set lab8-pb07 --revision lab8        # or change the Application manifest in Git (required when managed declaratively)
argocd app get lab8-pb07 --hard-refresh
Prevention and best practices
  • In production, point immutable references (tags or commit SHAs), while development points to branches; preview environments use the Pull Request generator, which automatically removes the application when its branch is deleted (#29, Lesson 3).
  • In CI, validate Application / ApplicationSet manifests: git ls-remote --exit-code "$REPO" "$REV".
Reproduction lab
source ~/gitops-lab/lab8/lab8.sh
mkdir -p ~/gitops-lab/lab8/pb07 && kubectl create configmap pb07 --from-literal=k=v --dry-run=client -o yaml > ~/gitops-lab/lab8/pb07/cm.yaml
cd ~/gitops-lab && git add lab8 && git commit -qm "lab8: pb07" && git push -q
l8_app pb07 lab8/pb07 --revision mian --sync-option CreateNamespace=true; sleep 5; l8_why pb07 | grep -i -A1 condition

See Lesson 1 Module 4 First Application,Lesson 3 Module 6 Pull Request generator.

#8 ComparisonError: … apps/podinfo/overlays/Prod: app path does not exist
ComparisonError  Failed to load target state: failed to generate manifest for source 1 of 1: rpc error: code = Unknown desc = apps/podinfo/overlays/Prod: app path does not exist

Source-verified util/app/path/path.go: "%s: %w" + app path does not exist; the same file also contains app path is absolute,app path outside root,app path is not a directory.

Symptom: Developers test on macOS (case-insensitive file system) and it works, but Argo CD reports that the path does not exist; or the directory was refactored and the Application was not updated; or the path begins with / .

Root cause: Repo Server checks out the repo in a Linux container; the path is case-sensitive, must be a directory relative to the repo root, and must not escape the repo root through a symbolic link. The directory must exist in targetRevision the commit being pointed to (existing on main but not on the lab8 branch will also fail).

Diagnostic commands
argocd app get lab8-pb08 -o json | jq -r '.spec.source | "\(.targetRevision) \(.path)"'
git -C ~/gitops-lab ls-tree -d --name-only -r origin/lab8 | grep -i 'overlays/prod'
lab8 apps/podinfo/overlays/Prod
apps/podinfo/overlays/prod
Fix
argocd app set lab8-pb08 --path apps/podinfo/overlays/prod
Prevention and best practices
  • Use lowercase directory names with kebab-case; in CI, check that each Application's path exists on the target branch (a simple yq + test -d script is enough).
  • When refactoring directories, add the new one first, switch the Application, then delete the old directory (two commits), to avoid an intermediate state.

See Lesson 3 Module 1 Repo layout.

#9 Helm values file not found: $values/… reference fails in a multi-source Application / values changed but the rendered output did not
ComparisonError  Failed to load target state: failed to generate manifest for source 1 of 2: rpc error: code = Unknown desc = … open values/myapp/prod.yaml: no such file or directory

Symptom: After managing the Helm chart and environment values separately (the chart comes from a Helm repository, the values from gitops-lab), the application reports that the values file does not exist; or the file exists but changes have no effect.

Root cause (three common cases):① In a multi-source application, a file from another source must be referenced as $<ref name>/path, and the referenced source must set ref: values; with a relative path Argo CD looks inside the chart source. ②valueFiles paths are relative to the chart directory, not the repo root. ③ The values source's targetRevision points to another branch, so you are editing a branch that is not the one being read.

Diagnostic commands
argocd app get myapp-prod -o json | jq '.spec.sources'
argocd app manifests myapp-prod --source git | grep -m3 -E 'image:|replicas:'
argocd app get myapp-prod --hard-refresh
Fix
spec:
  sources:
  - repoURL: https://github.com/<you>/gitops-lab
    targetRevision: main
    ref: values                                  # provides files only; does not render
  - repoURL: https://github.com/<you>/gitops-lab
    targetRevision: main
    path: apps/myapp
    helm:
      valueFiles:
      - $values/values/myapp/prod.yaml           # reference the source above via $values
      ignoreMissingValueFiles: false             # keep false in production: a missing file should fail
Prevention and best practices
  • With multiple sources, both sources should use the same release cadence (the same tag, or promoted together); otherwise you get a new chart with old values.
  • Do not use ignoreMissingValueFiles: true to hide errors; use argocd app manifests to review the final rendered output in code review.
  • Since v3.5, Helm 4.x is built in (upgrade notes: “Helm was upgraded to 4.2.0”); template behavior differences need to be compared with helm template before upgrading.

See Lesson 2 Module 2 Multi-source Application and separating Helm values.

#10 InvalidSpecError: application destination server '…' and namespace 'podinfo-prod' do not match any of the allowed destinations in project 'team-a'
CONDITION         MESSAGE
InvalidSpecError  application destination server 'https://kubernetes.default.svc' and namespace 'podinfo-prod' do not match any of the allowed destinations in project 'team-a'

Source-verified util/argo/argo.go: application destination server '%s' and namespace '%s' do not match any of the allowed destinations in project '%s'.

Symptom: Team A copied Team B's Application template and deployed it to a namespace it does not own; or the platform team added a new cluster and the project's destinations was not updated; or destination.name is used while the project only lists server.

Root cause: AppProject is the multi-tenant boundary: spec.destinations lists allowed (cluster, namespace) combinations, supporting wildcards and ! negation. An Application that does not match is not reconciled (or synced); this is the intended protective behavior.

Diagnostic commands
argocd proj get team-a
kubectl -n argocd get appproject team-a -o jsonpath='{.spec.destinations}' | jq
argocd app get podinfo-prod -o json | jq '.spec.destination'
Fix

First ask, “Should this application be deployed there?” If the Application was written wrongly, change the Application; if it really is needed, the platform team changes the project in Git:

spec:
  destinations:
  - {server: https://kubernetes.default.svc, namespace: 'team-a-*'}
  - {name: lab2, namespace: 'team-a-*'}
Prevention and best practices
  • Namespaces are split by team prefix (team-a-*), and the project destination uses a prefix wildcard; do not write namespace: '*' just to “get it running.”
  • Project definitions belong to the platform team: keep them in a separate directory protected by CODEOWNERS (GitHub course).
Reproduction lab
l8_app pb10 lab8/pb07 --dest-namespace default; sleep 3; l8_why pb10 | grep InvalidSpecError
argocd app set lab8-pb10 --dest-namespace lab8-pb10 && l8_why pb10 | grep -c InvalidSpecError

See Lesson 4 Module 1 AppProject boundaries,Module 2 Sources, destinations and allowlists.

#11 InvalidSpecError: application repo https://github.com/… is not permitted in project 'team-a'
InvalidSpecError  application repo https://github.com/<you>/charts-sandbox is not permitted in project 'team-a'

Source-verified util/argo/argo.go: application repo %s is not permitted in project '%s'.

Symptom: A team wants to reference a new Helm repository or a forked repo; or the second source of a multi-source application (ref: values) has not been added to the project; or the URL is written as git@github.com:… while the project has https://….

Root cause:spec.sourceRepos is the list of allowed source URLs (supports globs and ! negation),every source must match, including the ref source and the chart repository addresses of Helm dependencies. Matching is string-based; SSH and HTTPS forms are not treated as the same repository.

Diagnostic commands
kubectl -n argocd get appproject team-a -o jsonpath='{.spec.sourceRepos}'; echo
argocd app get myapp -o json | jq -r '.spec.source.repoURL // .spec.sources[].repoURL'
Fix
argocd proj add-source team-a 'https://github.com/<you>/*'      # or change the project YAML in Git
Prevention and best practices
  • The source allowlist is part of supply-chain control: only allow in-organization repositories and reviewed Helm / OCI repositories; mirror external charts to an internal registry first.
  • Use one URL form across the whole organization (all HTTPS or all SSH).

See Lesson 4 Module 2,Lesson 5 Module 7 Supply chain.

#12 existing application spec is different, use upsert flag to force update (CLI and Git both declare the same Application)
$ argocd app create podinfo-dev --repo … --path apps/podinfo/overlays/dev …
FATA[0001] rpc error: code = InvalidArgument desc = existing application spec is different, use upsert flag to force update

Source-verified server/application/application.go: existing application spec is different, use upsert flag to force update.

Symptom: The CI script runs argocd app create every time; one day someone also declared an Application with the same name in Git (App of Apps), or changed parameters in the UI — CI starts failing; adding --upsert makes both sides keep overwriting each other's changes.

Root cause: One Application has two “sources of truth”: imperative (CLI / UI / API) and declarative (the Application manifest in Git, synced by a parent app). When the parent app has selfHeal enabled, it reverts the CLI's changes; the CLI --upsert changes them back again.

Diagnostic commands
kubectl -n argocd get application podinfo-dev -o jsonpath='{.metadata.annotations.argocd\.argoproj\.io/tracking-id}'; echo
argocd app list -o wide | grep -E 'root|apps'           # whether a parent app manages it
kubectl -n argocd get application podinfo-dev -o yaml | grep -A3 managedFields | head
root:argoproj.io/Application:argocd/podinfo-dev
Fix
  • Establish a single source of truth: in production, the Application manifest lives only in Git (argocd/apps/ synced by root ), CI only changes Git (image tags, values) and does not call argocd app create/set.
  • When CI needs to wait for the result, use only read-only operations: argocd app wait podinfo-dev --health --sync --timeout 300.
Prevention and best practices
  • Use RBAC to restrict people's and CI's permissions on applications, update ; in production projects, prohibit changing parameters through the UI (parameter overrides).
  • The tracking-id annotation tells you “who manages this object”; look at it first when investigating something that keeps getting reverted.

See Lesson 3 Module 2 App of Apps and bootstrap,Lesson 6 Module 1 Who changes Git.

Four gates an Application must pass from “created” to “comparable”: which stage the problem is in ① Access Argo CDCLI/UI → argocd-serverTLS · gRPC / gRPC-Web#1 #2 #3 #12 ② Access Git / Helmrepo-server · credentials Secretknown_hosts · CA#4 #5 #6 ③ Resolve and renderls-remote → SHA → checkoutkustomize / helm template#7 #8 #9 ④ Project validationsourceRepos · destinationsInvalidSpecError#10 #11 Where the error appears① → CLI terminal / browser② → STATUS / MESSAGE in argocd repo list③ → Condition ComparisonError (Sync=Unknown)④ → Condition InvalidSpecError Where to look for logs① → argocd-server (including Dex)② ③ → argocd-repo-server④ → argocd-application-controllerRendered results are cached in Redis: after a change, use --hard-refresh
Figure 1-1 Four gates: the same “application won't start” — the error location determines the troubleshooting direction
Credential match order (#4): the URL must match repoURL secret-type: repositoryurl exactly matches repoURLpreferred.git suffix and case both count secret-type: repo-credsurl is a prefix of repoURLlongest prefix winsfor the whole organization nothing matchesanonymous accessprivate repo → authentication requiredSSH → known_hosts still needed (#5)
Figure 1-2 Credentials are matched from exact to fuzzy

“Application won't start” troubleshooting decision tree

Answer step by step from the first symptom you see to reach the most likely issue number and the first command. Each conclusion maps to an issue detail in this module or another module.

Environment kind cluster lab, Argo CD v3.x,gitops-lab 's lab8 branch, AppProject lab8; already executed source ~/gitops-lab/lab8/lab8.sh. Output is an example (Condition text format checked against v3.6.1 source); names and times depend on actual output.

Experiment 1-A: revision and path (#7, #8)

Prepare a minimal manifest directory and push it:
mkdir -p ~/gitops-lab/lab8/pb07
kubectl create configmap pb07 --from-literal=k=v --dry-run=client -o yaml > ~/gitops-lab/lab8/pb07/cm.yaml
cd ~/gitops-lab && git add lab8 && git commit -qm "lab8: pb07" && git push -q
Wrong branch:
l8_app pb07 lab8/pb07 --revision mian --sync-option CreateNamespace=true
sleep 5; l8_why pb07 | tail -2
ComparisonError: Failed to load target state: failed to generate manifest for source 1 of 1: rpc error: code = Unknown desc = unable to resolve 'mian' to a commit SHA
Wrong path (case):
argocd app set lab8-pb07 --revision lab8 --path lab8/PB07
argocd app get lab8-pb07 --hard-refresh >/dev/null; l8_why pb07 | tail -1
ComparisonError: Failed to load target state: failed to generate manifest for source 1 of 1: rpc error: code = Unknown desc = lab8/PB07: app path does not exist
Fix and sync:
argocd app set lab8-pb07 --path lab8/pb07 && argocd app sync lab8-pb07 && argocd app wait lab8-pb07 --health --timeout 60

Experiment 1-B: project boundary (#10, #11)

l8_app pb10 lab8/pb07 --dest-namespace default
sleep 3; l8_why pb10 | grep InvalidSpecError
InvalidSpecError: application destination server 'https://kubernetes.default.svc' and namespace 'default' do not match any of the allowed destinations in project 'lab8'
argocd app set lab8-pb10 --dest-namespace lab8-pb10 --repo https://github.com/argoproj/argocd-example-apps --path guestbook --revision HEAD
sleep 3; l8_why pb10 | grep InvalidSpecError
InvalidSpecError: application repo https://github.com/argoproj/argocd-example-apps is not permitted in project 'lab8'

Both errors mean the project is protecting you: first confirm intent, then decide whether to change the Application or the project.

Experiment 1-C: repo credentials (#4) and cleanup

argocd repo add https://github.com/<you>/does-not-exist-private --username x --password wrong; echo "exit=$?"
argocd repo list | tail -2

The failed repo add does not save the repo; if your repo is public, GitHub also returns an authentication failure for a non-existent repo — this is GitHub deliberately not revealing whether private repos exist.

Cleanup:
argocd app delete lab8-pb07 lab8-pb10 --yes --wait; kubectl delete ns lab8-pb07 --ignore-not-found

Teaching videos (titles and channels verified via YouTube oEmbed)

▶
5 common Argo CD issues and how to fix them — Octopus Deploy
English · overview of common issues
▶
ArgoCD Tutorial for Beginners | GitOps CD for Kubernetes — TechWorld with Nana
English · install, login, first Application (background for #1, #2, #7, #8)

No verified video was found that specifically covers Ingress redirect loops, known_hosts, private CA and multi-source troubleshooting. $values Below is a 3-minute storyboard you can record yourself:

Shot 1 (0:00) Figure 1-1 four gates; argocd login x509 reported, plus --insecure succeeds, explain how production should handle it.
Shot 2 (0:45) Change targetRevision to mian, a ComparisonError appears in the UI; git ls-remote and compare.
Shot 3 (1:30) Path case error → app path does not exist; git ls-tree find the correct path.
Shot 4 (2:15) Deploy to default namespace rejected by the project; show argocd proj get and InvalidSpecError.

Official docs

or get ≥ 70% in the “Quiz”

Module 2 · Part A: Sync, diff and health (issues 13–25)

08:00 – 16:00 · permanent OutOfSync, defaults and Server-Side Diff, annotations too long and SSA, CRDs and namespaces, hooks and operation locks, Progressing / Degraded, prune, shared resources, deletion and finalizers
8 minCompare → Sync → Health13 issues
Learning objectives
  • Distinguish three independent states: Sync Status (whether desired and live state match, determined by diff comparison),Operation State (whether the latest sync operation succeeded: Running / Succeeded / Failed / Error),Health Status (whether the resource itself is ready: Healthy / Progressing / Degraded / Suspended / Missing / Unknown). “Synced but Degraded” and “OutOfSync but Healthy” are both common.
  • Explain the three main sources of OutOfSync loops: another controller changed a field (HPA, webhook, operator),the API Server filled in defaults or normalized values (invisible to client-side diff),unstable rendering (random values, timestamps,lookup); know which category ignoreDifferences,RespectIgnoreDifferences=true, and Server-Side Diff (default for SSA applications since 3.6) each solve.
  • Remember the sync order: phase (PreSync → Sync → PostSync; failures go to SyncFail) → wave (lower numbers first) → kind (Namespace, CRD, etc. first) → name; after each wave is applied, wait for health before moving to the next wave.

Enter keywords (such as replicas,webhook,Too long,CRD,namespace,hook,in progress,Progressing,deadline,prune,shared,finalizer) to filter; click a row to jump to the details.

#13 Permanent OutOfSync: spec.replicas rewritten by HPA / webhook-injected fields; auto-sync and self-heal fight each other
===== apps/Deployment podinfo-prod/podinfo ======
150c150
<   replicas: 7
---
>   replicas: 3

Symptom: The application is always OutOfSync; with selfHeal enabled, Argo CD keeps changing the replica count back to 3, HPA scales it back up to 7, and Pods are created and deleted repeatedly; or Istio / Linkerd / a cloud vendor's mutating webhook injects a sidecar or annotations into the Pod template, so the diff never goes away.

Root cause: Git declares a field owned by another controller. The “single source of truth” in GitOps should only cover the fields you actually manage.

Diagnostic commands
argocd app diff podinfo-prod                            # see exactly which field
kubectl -n podinfo-prod get hpa
kubectl -n podinfo-prod get deploy podinfo --show-managed-fields -o yaml | grep -B2 -A6 'manager: kube-controller-manager\|manager: argocd'
Fix

Preferred: remove from Git replicas (let HPA fully own it). When it cannot be removed (for example, the chart forces its output), use ignoreDifferences and also make sync respect it:

spec:
  ignoreDifferences:
  - group: apps
    kind: Deployment
    jsonPointers: [/spec/replicas]
  # or ignore by field manager: managedFieldsManagers: [kube-controller-manager]
  syncPolicy:
    syncOptions:
    - RespectIgnoreDifferences=true      # otherwise sync still writes replicas back to 3
Prevention and best practices
  • Global ignore rules (needed by all applications) go in the argocd-cm of resource.customizations.ignoreDifferences.<group_kind>, for example the caBundle injected by webhooks.
  • Since v3.0 the system-level ignoreDifferences is also used by default to ignore resource update events (ignoreDifferencesOnResourceUpdates), and by default ignores the status field of all resources — reducing pointless reconciliation.
  • When selfHeal fights with something, watch whether argocd_app_sync_total grows abnormally; that is the earliest alert signal (Lesson 7).
Reproduction lab
l8_app pb13 apps/podinfo/overlays/dev --revision main --dest-namespace lab8-pb13 --sync-option CreateNamespace=true && argocd app sync lab8-pb13
kubectl -n lab8-pb13 scale deploy podinfo --replicas 4      # simulates HPA
argocd app get lab8-pb13 --refresh | grep -E 'Sync Status|Deployment'

See Lesson 2 Module 6 ignoreDifferences,Lesson 7 Module 5 OutOfSync loops.

#14 OutOfSync but no substantive difference visible in diff: cpu: 1000m vs "1", empty fields, field ordering (defaults and normalization)
<         cpu: "1"
---
>         cpu: 1000m
…
<     protocol: TCP
---
>     (absent)

Symptom: Right after a successful sync it becomes OutOfSync again; the differences are only notation (quantity units,protocol: TCP such API Server defaults,null and empty maps), or fields filled in on CRDs by conversion / defaulting webhooks.

Root cause: Legacy diff approximates the API Server's behavior on the client with a three-way merge, so it cannot know server-side defaults, admission webhooks or CRD schema normalization. Server-Side Diff Sending an SSA dry-run to the API Server gives “what it would look like if applied now,” compared with the live object; this eliminates these false diffs at the root.

Diagnostic commands
argocd app diff lab8-pb14
argocd app diff lab8-pb14 --server-side-diff      # compare the results of both strategies (the CLI supports this flag; check argocd app diff --help)
kubectl -n argocd get application lab8-pb14 -o jsonpath='{.metadata.annotations.argocd\.argoproj\.io/compare-options}'
Fix
metadata:
  annotations:
    argocd.argoproj.io/compare-options: ServerSideDiff=true      # enable for a single application
# Global: controller.diff.server.side: "true" in argocd-cmd-params-cm
# Since v3.6, applications that enable the ServerSideApply=true sync option use Server-Side Diff automatically

In the short term you can also write values in Git in the same normalized form the API Server returns (cpu: "1" → write the live value).

Prevention and best practices
  • For a new platform, enable Server-Side Diff globally from the start; note it adds dry-run requests to the API Server (3.6 upgrade notes: results are cached and only requested on refresh, a new revision, a spec change, or a resource version change).
  • Since 3.6 validating webhooks also take part in the diff stage: rejected resources show up as diff errors instead of failing only at sync time — good, but be aware that the error now appears at a different point.

See Lesson 2 Module 6,Lesson 7 Module 5.

#15 metadata.annotations: Too long: must have at most 262144 bytes (large CRD / large ConfigMap sync fails)
one or more objects failed to apply, reason: CustomResourceDefinition.apiextensions.k8s.io "prometheuses.monitoring.coreos.com" is invalid: metadata.annotations: Too long: must have at most 262144 bytes
 -Additional Info: This error usually means that you are trying to add a large resource on client side. Consider using Server-side apply or syncing with replace enabled. Note: Syncing with Replace enabled is potentially destructive as it may cause resource deletion and re-creation.

Source-verified util/argo/argo.go The AugmentSyncMsg (the message) when matched to metadata.annotations: Too long: must have at most 262144 bytes , the Additional Info above is appended; one or more objects failed to apply comes from gitops-engine/pkg/sync/sync_context.go. Wording may also differ across Kubernetes versions, for example may not be more than 262144 bytes (the Argo CD 3.3 upgrade notes cite this form).

Symptom: Sync fails when deploying kube-prometheus-stack, Argo CD itself (the ApplicationSet CRD is very large from 3.3 onward), or a large Grafana dashboard ConfigMap.

Root cause: Client-side apply writes the entire object into kubectl.kubernetes.io/last-applied-configuration an annotation, and all annotations combined must not exceed 256 KiB.

Diagnostic commands
argocd app get lab8-pb15 --show-operation | sed -n '/Operation/,$p' | head -20
kubectl get crd prometheuses.monitoring.coreos.com -o json | jq '.metadata.annotations | to_entries | map(.value | length)'
Fix
spec:
  syncPolicy:
    syncOptions:
    - ServerSideApply=true          # SSA does not write the last-applied annotation; Argo CD adds resolve conflicts automatically
# For a single resource only: add the annotation argocd.argoproj.io/sync-options: ServerSideApply=true to that resource
Prevention and best practices
  • New applications default to ServerSideApply=true; when migrating from client-side apply, Argo CD performs a client-side apply migration (the term used in the upgrade notes: ClientSideApplyMigration), do not turn it off casually.
  • Do not prefer Replace=true: for CRDs it means delete and recreate, which may cascade and delete all custom resource instances.
  • From v3.6, SSA applications automatically use Server-Side Diff (#14); watch API Server load during upgrades.

See Lesson 2 Module 3 Sync options,Lesson 7 Module 7 Upgrades.

#16 The Kubernetes API could not find monitoring.coreos.com/ServiceMonitor … Make sure the "ServiceMonitor" CRD is installed on the destination cluster.
The Kubernetes API could not find monitoring.coreos.com/ServiceMonitor for requested resource lab8-pb16/podinfo. Make sure the "ServiceMonitor" CRD is installed on the destination cluster.

Source-verified AugmentSyncMsg: when the underlying message contains the server could not find the requested resource and the cluster has no such Kind, this text is output; if the Kind exists but the version differs, output The Kubernetes API could not find version "…" of … Version "…" of … is installed on the destination cluster.

Symptom: The application includes custom resources such as ServiceMonitor / Certificate / Rollout, but the target cluster does not yet have the corresponding operator; or the same application contains both a CRD and its CRs, and the dry-run fails on the first sync; or after a CRD version upgrade, the old v1alpha1 has been removed.

Root cause: Before syncing, Argo CD dry-runs all resources, and the dry-run requires the API Server to recognize the type. When a CRD and its CR are in the same sync, the CR's dry-run runs before the CRD is created.

Diagnostic commands
kubectl --context kind-lab api-resources | grep -i servicemonitor || echo "CRD not installed"
argocd app get lab8-pb16 --show-operation | grep -i 'could not find'
Fix
metadata:
  annotations:
    argocd.argoproj.io/sync-options: SkipDryRunOnMissingResource=true   # add to the CR: skip the dry-run when the type does not exist
# Also use waves to ensure the CRD comes before the CR: the CRD's sync-wave is "-1", the CR's is "1"
# Better: deploy the operator and its CRDs as a separate "platform layer" application, ahead of business applications (order them with waves in App of Apps)
Prevention and best practices
  • Layering: platform platform layer (CRDs, operators, cert-manager, monitoring stack) → business applications; ServiceMonitors in business charts are controlled by a values switch (serviceMonitor.enabled).
  • When upgrading a CRD version, first confirm the version in kubectl api-resources and then change the version of the CR in Git apiVersion.

See Lesson 2 Module 3,Module 4 Sync Waves.

#17 namespaces "lab8-pb17" not found (the target namespace does not exist)
one or more objects failed to apply, reason: namespaces "lab8-pb17" not found

Symptom: The first sync in a new environment fails; or someone manually deleted the namespace (taking all its resources with it), and it fails again after self-healing.

Root cause: Argo CD does not create destination.namespace namespaces by default. A namespace can be ① created by CreateNamespace=true ; ② part of the manifests (a Namespace object, which requires the project to allow the cluster-scoped Namespace resource, #37); ③ pre-created by the platform team.

Diagnostic commands
kubectl get ns lab8-pb17
argocd app get lab8-pb17 -o json | jq '.spec.syncPolicy.syncOptions'
Fix
spec:
  syncPolicy:
    syncOptions: [CreateNamespace=true]
    managedNamespaceMetadata:            # when consistent labels are needed (for example Pod Security or network policy selectors)
      labels: {pod-security.kubernetes.io/enforce: baseline, team: lab8}
Prevention and best practices
  • In a multi-tenant platform, the platform layer (generated per team by an ApplicationSet) creates namespaces together with ResourceQuota, LimitRange and NetworkPolicy; team applications do not create namespaces.
  • CreateNamespace=true Namespaces created by will not be deleted when the application is deleted — this is an intentional safety design.
Reproduction lab
l8_app pb17 lab8/pb07 && argocd app sync lab8-pb17; argocd app set lab8-pb17 --sync-option CreateNamespace=true && argocd app sync lab8-pb17

See Lesson 2 Module 3.

#18 InvalidSpecError: Namespace for podinfo apps/v1, Kind=Deployment is missing.
InvalidSpecError  Namespace for podinfo apps/v1, Kind=Deployment is missing.

Source-verified controller/state.go: Namespace for %s %s is missing. (the second argument is the string form of the GVK, such as apps/v1, Kind=Deployment).

Symptom: The Application's destination.namespace is left empty (wanting the manifests to decide), but namespace-scoped resources in the manifests do not specify metadata.namespace.

Root cause: Argo CD only fills the destination.namespace for namespace-scoped resources that have no namespace; when neither side has one, the target cannot be determined.

Diagnostic commands
argocd app get lab8-pb18 -o json | jq '.spec.destination'
argocd app manifests lab8-pb18 | yq 'select(.metadata.namespace == null) | .kind + "/" + .metadata.name'
Fix

Set destination.namespace (recommended), or unify it in Kustomize namespace:.

Prevention and best practices
  • Convention: in manifests, do not write namespaces; the Application (or Kustomize overlay) injects them, so the same base can be deployed to multiple environments.
  • When a namespace is explicitly written in the manifests, it overrides the destination and must still pass the project's destinations validation (namespace … is not permitted in project, #37).

See Lesson 1 Module 4.

#19 Sync stays Running: waiting for completion of hook batch/Job/db-migrate
Operation:          Sync
Phase:              Running
Message:            waiting for completion of hook batch/Job/db-migrate

Source-verified gitops-engine/pkg/sync/sync_context.go: waiting for %s %s/%s/%s, with the reason completion of hook / healthy state of / deletion of / pruning confirmation of, and with multiple tasks, append and %d more hooks|resources.

Symptom: The database migration Job in PreSync cannot pull its image (ImagePullBackOff), is waiting for a database connection, or backoffLimit is very large and keeps retrying; the sync stays here forever, and subsequent deployments are blocked too (#20).

Root cause: A hook Job only lets Argo CD proceed once it completes (succeeded or failed); if the Job itself has no timeout, it waits forever. Similarly, waiting for healthy state of apps/Deployment/podinfo means a resource in some wave has been unhealthy for a long time.

Diagnostic commands
argocd app get lab8-pb19 --show-operation | grep -E 'Phase|Message'
kubectl -n lab8-pb19 get job,pod -l job-name=db-migrate
kubectl -n lab8-pb19 describe pod -l job-name=db-migrate | tail -15
Fix
argocd app terminate-op lab8-pb19              # first terminate the stuck operation
# after fixing the Job manifest, sync again
apiVersion: batch/v1
kind: Job
metadata:
  name: db-migrate
  annotations:
    argocd.argoproj.io/hook: PreSync
    argocd.argoproj.io/hook-delete-policy: BeforeHookCreation   # delete the old Job before the next sync, to avoid "already exists"
spec:
  activeDeadlineSeconds: 600        # hooks must have a timeout
  backoffLimit: 2
Prevention and best practices
  • On all hook Jobs, set activeDeadlineSeconds and a small backoffLimit; use SyncFail hooks to send alerts or clean up.
  • Migrations must be backward compatible (expand first, then contract), so the old version can still run when a hook fails (interview Q49).
Reproduction lab
mkdir -p ~/gitops-lab/lab8/pb19 && cat > ~/gitops-lab/lab8/pb19/hook.yaml <<'EOF'
apiVersion: batch/v1
kind: Job
metadata: {name: db-migrate, annotations: {argocd.argoproj.io/hook: PreSync, argocd.argoproj.io/hook-delete-policy: BeforeHookCreation}}
spec:
  template:
    spec:
      restartPolicy: Never
      containers: [{name: m, image: busybox:1.37, command: [sh, -c, "echo waiting for db; sleep 3600"]}]
EOF
cp ~/gitops-lab/lab8/pb07/cm.yaml ~/gitops-lab/lab8/pb19/ && cd ~/gitops-lab && git add lab8 && git commit -qm "lab8: pb19" && git push -q
l8_app pb19 lab8/pb19 --sync-option CreateNamespace=true && argocd app sync lab8-pb19 --async; sleep 10; l8_why pb19 | grep -i message

See Lesson 2 Module 4 Sync Waves and resource hooks.

#20 FailedPrecondition: another operation is already in progress
$ argocd app sync lab8-pb19
FATA[0000] rpc error: code = FailedPrecondition desc = another operation is already in progress

Source-verified util/argo/argo.go: ErrAnotherOperationInProgress = status.Errorf(codes.FailedPrecondition, "another operation is already in progress").

Symptom: In the CI pipeline, the argocd app sync step fails; or manual sync fails when auto-sync is enabled; often happens together with the stuck hook in #19.

Root cause: Each Application can run only one operation at a time (.operation field). While the previous operation is still Running (waiting for hooks, waiting for health, or in retry backoff), new sync requests are rejected.

Diagnostic commands
kubectl -n argocd get application lab8-pb19 -o jsonpath='{.status.operationState.phase}{"  "}{.status.operationState.message}{"\n"}'
kubectl -n argocd get application lab8-pb19 -o jsonpath='{.operation}'; echo
Fix
argocd app terminate-op lab8-pb19
argocd app wait lab8-pb19 --operation --timeout 60 && argocd app sync lab8-pb19
Prevention and best practices
  • CI should not actively sync for applications with auto-sync enabled: only change Git, then argocd app wait.
  • The automatic sync retry policy (syncPolicy.retry.limit,backoff) must have a limit; otherwise a failing sync holds the operation lock for a long time, with messages like … Retrying attempt #3 at 10:21AM. (in the source it is %s. Retrying attempt #%d at %s.).

See Lesson 7 Module 5 Sync failures.

#21 Health stuck at Progressing: Ingress / Service of type LoadBalancer (kind has no load balancer)
GROUP              KIND     NAMESPACE   NAME     STATUS  HEALTH       HOOK  MESSAGE
                   Service  lab8-pb21   podinfo  Synced  Progressing
networking.k8s.io  Ingress  lab8-pb21   podinfo  Synced  Progressing

Source-verified gitops-engine/pkg/health/health_ingress.go and health_service.go: the Ingress's status.loadBalancer.ingress is empty, or a LoadBalancer-type Service has no address assigned, and the health status is Progressing.

Symptom: The application syncs successfully and all Pods are Running, but the application health is stuck at Progressing forever; subsequent waves that depend on health, PostSync hooks, the next RollingSync step, and Rollouts are all waiting.

Root cause: kind has no LoadBalancer implementation by default; the Ingress controller did not write back an address (not installed, IngressClass mismatch, or publish-service not enabled on the controller). This is not an Argo CD bug, but the real state of “no address assigned.”

Diagnostic commands
kubectl -n lab8-pb21 get svc,ingress -o wide
kubectl get ingressclass
argocd app get lab8-pb21 | grep Progressing
Fix
  • Lab environment: kind uses ClusterIP + port-forward, or install cloud-provider-kind / MetalLB to assign addresses; enable address write-back on the Ingress controller.
  • For resources that genuinely do not need an address, you can override with a custom Lua health check (resource.customizations.health.networking.k8s.io_Ingress), but be aware that this masks real failures.
Prevention and best practices
  • Health checks are the “brakes” of GitOps automation: do not turn them off just to get green; make the environment satisfy them instead.
  • A PVC stuck in Pending (other than WaitForFirstConsumer) is also Progressing; a StatefulSet's partition rolling update also shows Progressing.

See Lesson 2 Module 5 Health checks.

#22 Degraded: Deployment "podinfo" exceeded its progress deadline (a bad image tag was auto-synced)
apps  Deployment  podinfo-dev  podinfo  Synced  Degraded  Deployment "podinfo" exceeded its progress deadline

Source-verified health_deployment.go: Deployment %q exceeded its progress deadline; in progress it is Waiting for rollout to finish: %d out of %d new replicas have been updated... , etc.

Symptom: CI changed the image tag to a version that does not exist (or an arm64 node pulls an amd64 image); auto-sync succeeded (Synced), and 10 minutes later the application became Degraded; the old ReplicaSet is still serving (protection from the rolling update), but all subsequent deployments are based on a bad desired state.

Root cause: Sync only guarantees that “the object has been written to the API Server,” not that “the new version runs.” The health check relies on the Deployment's progressDeadlineSeconds (default 600 seconds) to report Degraded.

Diagnostic commands
argocd app get podinfo-dev | grep -E 'Degraded|Progressing'
kubectl -n podinfo-dev get rs,pod -l app.kubernetes.io/name=podinfo
kubectl -n podinfo-dev describe pod -l app.kubernetes.io/name=podinfo | grep -A3 -E 'Failed|BackOff'
Fix
cd ~/gitops-lab && git revert --no-edit HEAD && git push          # rollback in GitOps = roll back Git
# Emergency: argocd app rollback requires auto-sync to be turned off first; otherwise the next reconciliation syncs the bad version again
Prevention and best practices
  • CI verifies that the image exists before changing Git (crane manifest,docker buildx imagetools inspect), and uses only immutable tags or digests.
  • Use Argo Rollouts + AnalysisTemplate so that a “bad version” is aborted automatically (#45); use Notifications' on-health-degraded triggers to alert (#47).

See Lesson 1 Module 5 State model,Lesson 6 Module 2 Rollouts.

#23 Resources deleted from Git still in the cluster: OutOfSync “requires pruning” / retained by Prune=false
GROUP  KIND       NAMESPACE   NAME       STATUS     HEALTH   HOOK  MESSAGE
       ConfigMap  lab8-pb23   old-flags  OutOfSync  Missing        ignored (requires pruning)

Symptom: After a refactor, a ConfigMap / CronJob was deleted but is still running in the cluster (for example, the old CronJob keeps running jobs); the application stays OutOfSync.

Root cause: Pruning is off by default: auto-sync requires syncPolicy.automated.prune: true, and manual sync requires --prune. In addition, argocd.argoproj.io/sync-options: Prune=false annotations permanently retain a resource,Prune=confirm require manual confirmation (the sync stops at waiting for pruning confirmation of …). If a resource's tracking information is lost (the first sync after switching tracking methods from v2 to v3 deletes the resource, #50), Argo CD cannot recognize it either.

Diagnostic commands
argocd app resources lab8-pb23 --orphaned=false | grep -i prun
kubectl -n lab8-pb23 get cm old-flags -o jsonpath='{.metadata.annotations}'; echo
argocd app get lab8-pb23 -o json | jq '.spec.syncPolicy'
Fix
argocd app sync lab8-pb23 --prune
# Automatic: syncPolicy.automated.prune: true; for critical resources (Namespace, PVC) keep Prune=false or Prune=confirm
Prevention and best practices
  • Review before enabling prune argocd app diff; for stateful resources (PVC, database CRs) add Prune=false / Delete=false (interview Q42).
  • Use PruneLast=true so that pruning happens after all waves, avoiding a brief outage caused by deleting old resources first.
  • Enable orphaned-resource monitoring in the project (orphanedResources.warn: true) to find resources that “no application manages.”

See Lesson 1 Module 7 Self-healing and pruning.

#24 SharedResourceWarning: ConfigMap/app-config is part of applications argocd/podinfo-staging and podinfo-dev
SharedResourceWarning  ConfigMap/app-config is part of applications argocd/podinfo-staging and podinfo-dev

Source-verified controller/state.go: %s/%s is part of applications %s and %s; when FailOnSharedResource=true is enabled, the sync fails with the message prefix Shared resource found: (controller/sync.go).

Symptom: Two applications render resources with the same name and namespace (a copy-pasted overlay forgot to change namespace / namePrefix; two charts both create the same ClusterRole); the two applications take turns “fighting” over the resource — after one syncs, the other becomes OutOfSync, and deleting one application may even delete the other's resources.

Root cause: Each resource can have only one tracking-id; the application synced later rewrites the tracking annotation, and the earlier application treats it as “needs repair” or “not mine.”

Diagnostic commands
kubectl -n podinfo-dev get cm app-config -o jsonpath='{.metadata.annotations.argocd\.argoproj\.io/tracking-id}'; echo
argocd app manifests podinfo-staging | yq 'select(.kind=="ConfigMap") | .metadata.namespace + "/" + .metadata.name'
Fix

Make each resource belong to only one application: correct the overlay's namespace/namePrefix; move cluster-level shared resources into a platform application. Then sync the two applications separately.

Prevention and best practices
  • Enable in production applications FailOnSharedResource=true, so conflicts become explicit failures.
  • In CI, render all applications and check (group, kind, namespace, name) uniqueness.

See Lesson 2 Module 7 Resource tracking methods.

#25 Application deletion stuck in Deleting: resources-finalizer.argocd.argoproj.io / DeletionError: Unable to delete application resources: …
DeletionError  Unable to delete application resources: …

Source-verified controller/appcontroller.go: Unable to delete application resources: %v; the finalizer name is resources-finalizer.argocd.argoproj.io (application_defaults.go).

Symptom:argocd app delete Afterwards the application keeps existing,metadata.deletionTimestamp is set; common causes: the target cluster is unreachable (the cluster was deleted), a child resource is stuck on its own finalizer (for example PVC kubernetes.io/pvc-protection, cert-manager, or cloud LB controllers), the AppProject has been deleted, or the controller lacks permission to delete some resource type.

Root cause: An application with resources-finalizer, when deleted, will cascade-delete all managed resources, and removes the finalizer only after every one has been deleted successfully. If any single resource cannot be deleted, the application stays in Deleting.

Diagnostic commands
kubectl -n argocd get application lab8-pb25 -o jsonpath='{.metadata.finalizers}{"\n"}{.metadata.deletionTimestamp}{"\n"}'
l8_why pb25 | grep -i deletion
argocd app resources lab8-pb25
kubectl -n lab8-pb25 get all,pvc -o name; kubectl get ns lab8-pb25 -o jsonpath='{.status.conditions}'
Fix
  • First fix the stuck resource (restore the cluster connection, or the controller that handles the child resource's finalizer).
  • Only when you have decided to abandon cascading deletion (for example, the cluster no longer exists) should you manually remove the Application's finalizer: kubectl -n argocd patch application lab8-pb25 --type json -p '[{"op":"remove","path":"/metadata/finalizers"}]'— this leaves orphaned resources behind, which must be recorded and cleaned up.
Prevention and best practices
  • Cluster deletion procedure: first delete (or non-cascading delete) the applications pointing to it, then unregister the cluster, and finally delete the cluster.
  • When you need to “delete the application but keep its resources,” use non-cascading deletion: argocd app delete APP --cascade=false.
  • From v3.6, health checks also run during deletion (upgrade notes: “Health Checks During Deletion”), so the reason a stuck resource is stuck is easier to see in the UI.
Reproduction lab
l8_app pb25 lab8/pb07 --sync-option CreateNamespace=true && argocd app sync lab8-pb25
kubectl -n lab8-pb25 patch cm pb07 --type merge -p '{"metadata":{"finalizers":["example.com/block"]}}'
argocd app delete lab8-pb25 --yes &; sleep 10; kubectl -n argocd get application lab8-pb25 -o jsonpath='{.metadata.deletionTimestamp}'; echo
kubectl -n lab8-pb25 patch cm pb07 --type json -p '[{"op":"remove","path":"/metadata/finalizers"}]'   # unblock; deletion completes

See Lesson 7 Module 6 Stuck deletion, finalizers and orphaned resources.

Compare → Sync → Health: which step each issue in this module falls into Compare (Controller)Desired (Repo Server rendering) vs live (cluster cache)Legacy / Server-Side Diff · ignoreDifferences#13 #14 #23 #24 Sync (Operation)dry-run → phase → wave → kind → applyHooks · wait for health per wave · operation lock#15 #16 #17 #18 #19 #20 Health (gitops-engine + Lua)Healthy / Progressing / DegradedSuspended / Missing / Unknown#21 #22 #25 The three states are independentSynced + Degraded: the object is written, but the new version does not run (#22)OutOfSync + Healthy: another controller changed a field, or there are resources waiting to be pruned (#13 #23)Operation Running: hooks / waves are waiting; new syncs are rejected at this point (#19 #20)Unknown: the comparison never completed (rendering failure → Module 1)
Figure 2-1 First determine which state is wrong, then look at the corresponding step

Sync execution simulator: phase → wave → hooks → health

Choose a scenario, click “Run,” and observe how a sync progresses through PreSync → wave -1 → wave 0 → wave 1 → PostSync, where it stops, and what the operation message is (the message format is taken from v3.6.1's sync_context.go, resource names are examples).

$ Waiting to run…
Environment Same as Module 0; requires apps/podinfo/overlays/dev exists in main. Output is an example.

Experiment 2-A: drift and ignoreDifferences (#13)

l8_app pb13 apps/podinfo/overlays/dev --revision main --dest-namespace lab8-pb13 --sync-option CreateNamespace=true
argocd app sync lab8-pb13 && kubectl -n lab8-pb13 scale deploy podinfo --replicas 4
argocd app get lab8-pb13 --refresh | grep -E '^Sync Status|Deployment'
Sync Status:        OutOfSync from main (…)
apps  Deployment  lab8-pb13  podinfo  OutOfSync  Healthy
kubectl -n argocd patch application lab8-pb13 --type merge -p '{"spec":{"ignoreDifferences":[{"group":"apps","kind":"Deployment","jsonPointers":["/spec/replicas"]}]}}'
argocd app get lab8-pb13 --refresh | grep -E '^Sync Status'
Sync Status:        Synced to main (…)

Experiment 2-B: stuck hook and operation lock (#19, #20)

Create it using the #19 “reproduction lab” lab8/pb19 and sync asynchronously, then:
argocd app sync lab8-pb19; argocd app get lab8-pb19 --show-operation | grep -E 'Phase|Message'
FATA[0000] rpc error: code = FailedPrecondition desc = another operation is already in progress
Phase:              Running
Message:            waiting for completion of hook batch/Job/db-migrate
argocd app terminate-op lab8-pb19
sed -i 's/sleep 3600/echo migrated/' ~/gitops-lab/lab8/pb19/hook.yaml && cd ~/gitops-lab && git commit -qam "lab8: pb19 fix" && git push -q
argocd app sync lab8-pb19 && argocd app wait lab8-pb19 --health --timeout 120

Experiment 2-C: stuck deletion (#25) and cleanup

Follow the #25 “reproduction lab” and observe deletionTimestamp is set while the application still exists; after removing the child resource's finalizer, deletion completes.
Cleanup:
l8_clean

Teaching videos (titles and channels verified via YouTube oEmbed)

▶
Mastering Argo CD Sync Waves: A Deep Dive into Effective GitOps Synchronization Strategies — DevOps & AI Toolkit
English · waves and hooks (#16, #19)
▶
Argo CD Ignore Differences — Codefresh
English · ignoreDifferences (#13)

No verified video was found that specifically covers Server-Side Diff, annotations too long, or stuck finalizer deletion. Storyboard:

Shot 1 (0:00) kubectl scale Create drift → OutOfSync; after adding ignoreDifferences + RespectIgnoreDifferences it becomes Synced.
Shot 2 (0:50) PreSync Job sleep 3600; the sync stops at waiting for completion of hook; a re-sync is rejected; terminate-op.
Shot 3 (1:40) Add a custom finalizer to a child resource; deletion of the application gets stuck; show deletionTimestamp and DeletionError; after removing it, deletion completes.

Official docs

or get ≥ 70% in the “Quiz”

Module 3 · Part A: ApplicationSet, multi-cluster and permissions (issues 26–38)

16:00 – 24:00 · generators and templates, AppSet deletion semantics, polling delay, cluster registration and kind networking, Casbin RBAC, SSO groups, v3 logs and fine-grained permissions, cluster-scoped resource allowlist, Applications in any namespace
8 minGenerate → register → authorize13 issues
Learning objectives
  • Know the ApplicationSet controller loop: generators produce parameters → render the template (recommended goTemplate: true + missingkey=error) → validate (duplicate names, project exists, target cluster exists) → according to the applicationsSync policy, create / update / delete Applications. AppSet errors are written to the AppSet's status.conditions, not on the Application.
  • Be able to use argocd appset generate (preview without applying),argocd appset get, and applicationset-controller logs to locate generation problems; be able to explain why deleting an AppSet by default deletes all the Applications it generated and their resources.
  • Be able to restate how an API request is authorized: authentication (local account / SSO JWT) → get the subject and groups (scopes) → g policy maps roles → p policy matching (resource, action, project/object) → deny first → if nothing matches, falls back to policy.default; and be able to read permission denied: applications, sync, team-a/podinfo-dev, sub: …, iat: ….

Enter keywords (such as duplicate,template,deleted,3 minutes,project,cluster,127.0.0.1,permission denied,groups,logs,update/*,Namespace,sourceNamespaces) to filter; click a row to jump to the details.

#26 ApplicationSet podinfo contains applications with duplicate name: podinfo
$ argocd appset get podinfo | sed -n '/CONDITION/,$p'
CONDITION                TYPE  STATUS  MESSAGE
ErrorOccurred            …     True    ApplicationSet podinfo contains applications with duplicate name: podinfo
ResourcesUpToDate        …     False   …

Source-verified applicationset/controllers/applicationset_controller.go: ApplicationSet %s contains applications with duplicate name: %s; the same place also has … contains an application with no name; a name must be set in the template's metadata.name or via a templatePatch (generateName is not supported).

Symptom: In a Matrix generator (cluster × environment), the template name only uses {{.name}}; or a List generator has an extra duplicate element. The whole AppSet stops updating —other normal Applications also stop being updated.

Root cause: Application names must be unique within the Argo CD namespace; the template name must be composed of fields that distinguish each set of parameters.

Diagnostic commands
argocd appset generate ~/gitops-lab/argocd/appsets/podinfo.yaml -o json | jq -r '.[].metadata.name' | sort | uniq -d
kubectl -n argocd logs deploy/argocd-applicationset-controller --tail=50 | grep -i duplicate
Fix
template:
  metadata:
    name: 'podinfo-{{.env}}-{{.name}}'        # environment + cluster, guarantees uniqueness (goTemplate syntax)
Prevention and best practices
  • In CI, run for each AppSet argocd appset generate (requires connecting to Argo CD; a rendering script can be used offline), and check that names are unique and at most 63 characters long (names are often also used as label values).
  • Naming convention: <app>-<env>-<cluster>.

See Lesson 3 Module 3 ApplicationSet controller and templates,Module 5 Matrix and Merge.

#27 failed to execute go template {{.path.basenamee}}: … map has no entry for key "basenamee"
ErrorOccurred  failed to execute go template podinfo-{{.path.basenamee}}: template: :1:19: executing "" at <.path.basenamee>: map has no entry for key "basenamee"

Source-verified applicationset/utils/utils.go: failed to execute go template %s: %w; and the source uniformly adds missingkey=error (around line 357 of the same file), so misspelled keys produce an error instead of silently rendering as empty.

Symptom: When migrating from the old fasttemplate syntax ({{path.basename}}) to goTemplate ({{.path.basename}}), a typo is made; or in the JSON/YAML file of the Git file generator, one environment is missing a key.

Root cause: In goTemplate mode, parameters are nested maps; accessing a non-existent key fails when missingkey=error is evaluated. If goTemplate is not enabled, the old template engine leaves unknown placeholders as they are, so the generated name contains {{…}} and produces a strange Application.

Diagnostic commands
argocd appset generate ~/gitops-lab/argocd/appsets/podinfo.yaml -o yaml | head -30
argocd appset get podinfo -o json | jq '.status.conditions'
Fix
spec:
  goTemplate: true
  goTemplateOptions: ["missingkey=error"]
  template:
    metadata:
      name: 'podinfo-{{.path.basename}}'
    spec:
      source:
        helm:
          values: |
            replicas: {{ default 1 .replicas }}     # use default (a Sprig function) for optional keys
Prevention and best practices
  • Use goTemplate for all new AppSets; for optional parameters use default/hasKey, and do not rely on “a missing key is empty.”
  • Helm syntax in templates ({{ .Values.x }}) conflicts with AppSet's goTemplate: keep Helm templates inside the chart, do not inline them in the AppSet's values, and when necessary use {{`{{ … }}`}} to escape.

See Lesson 3 Module 3.

#28 Deleting (or wrongly editing the generator of) an ApplicationSet deletes all the Applications it generated and their workloads together
applicationset.argoproj.io "podinfo" deleted
application.argoproj.io/podinfo-prod-lab   deleted
application.argoproj.io/podinfo-prod-lab2  deleted
(the Deployment and Service in the podinfo-prod namespace are then cascade-deleted)

Official docs An Application with resources-finalizer.argocd.argoproj.io deletion cascades; an ApplicationSet setting .syncPolicy.preserveResourcesOnDeletion: true can keep deployed resources when the AppSet is deleted.

Symptom: When refactoring directories, an AppSet was moved from argocd/appsets/ to elsewhere, and the root app pruned it; or the path wildcard of the Git directory generator was written wrong, so the generator returns an empty list — the AppSet concludes “these Applications are no longer needed” and deletes them all.

Root cause: The AppSet is the “owner” of its Applications (ownerReference); the default policy sync allows create, update and delete; Applications carry a resource finalizer by default, so deletion cascades all the way to the workloads.

Diagnostic commands
kubectl -n argocd get applicationset podinfo -o jsonpath='{.spec.syncPolicy}'; echo
kubectl -n argocd get application -l app.kubernetes.io/instance=podinfo 2>/dev/null | head      # depends on your labels
argocd appset generate ~/gitops-lab/argocd/appsets/podinfo.yaml -o json | jq length            # whether the generator returns 0 items
Fix

Restore from Git (git revert) and the root app recreates the AppSet; workloads are resynced (stateful data relies on backups). Long-term configuration:

spec:
  syncPolicy:
    applicationsSync: create-update            # do not delete Applications (create-only / create-update / create-delete / sync)
    preserveResourcesOnDeletion: true          # do not cascade-delete resources when the AppSet is deleted
# Global: applicationsetcontroller.policy: create-update in argocd-cmd-params-cm
Prevention and best practices
  • Production AppSets default to create-update + preserveResourcesOnDeletion: true; deleting an environment goes through a separate review process.
  • The root app for argocd/appsets/ directories turns off automatic prune, or add to the AppSet argocd.argoproj.io/sync-options: Prune=false.
  • This is the prototype for interview post-mortem question Q41.
  • Migration pitfall (Lesson 3): before migrating hand-written podinfo-dev/staging/prod to ApplicationSet podinfo (argocd/appsets/podinfo.yaml, project platform,preserveResourcesOnDeletion: true, generated apps have no finalizer) — if old Applications carry resources-finalizer, deleting them cascades to delete running workloads — first delete non-cascading (argocd app delete APP --cascade=false) or first remove the finalizer, then let the AppSet take over applications with the same name.

See Lesson 3 Module 3,Module 7 Progressive sync.

#29 A newly added environment directory appears only after 3 minutes / preview environments are slow to be created (generator polling interval)
git push a new directory apps/podinfo/overlays/qa → podinfo-qa does not appear in argocd app list for a long time

Official docs The Git generator polls by default every requeueAfterSeconds (default 3 minutes, i.e. 180 seconds); configuring a webhook can eliminate the delay.

Symptom: Developers think “it didn't take effect” after pushing and keep pushing empty commits; with the PR generator, preview environments are slower (SCM API polling, also affected by rate limiting).

Root cause: The ApplicationSet controller and the Application controller each poll: the AppSet generator discovers the new directory → creates the Application → the Application controller fetches and compares in the next reconciliation cycle (timeout.reconciliation default 120 seconds, plus up to 60 seconds of jitter). Combined, the two can add up to several minutes.

Diagnostic commands
kubectl -n argocd get applicationset podinfo -o jsonpath='{.spec.generators[0].git.requeueAfterSeconds}'; echo
kubectl -n argocd logs deploy/argocd-applicationset-controller --since=10m | grep -iE 'webhook|generated'
kubectl -n argocd get secret argocd-secret -o jsonpath='{.data}' | jq 'keys | map(select(startswith("webhook")))'
Fix
  • Configure a GitHub webhook pointing to https://argocd.example.com/api/webhook (Application refresh) and the webhook endpoint of the ApplicationSet controller, and in argocd-secret set webhook.github.secret.
  • Only when the webhook is unavailable, reduce requeueAfterSeconds, and evaluate the impact on Git server / API rate limits (#49).
Prevention and best practices
  • Explain the “eventual consistency” timing expectations to developers, and provide argocd app get --refresh self-service commands.
  • The webhook must verify its secret; a read-only webhook endpoint can be exposed separately without exposing the whole UI.

See Lesson 3 Module 4 Generators,Lesson 7 Module 3 Repo Server.

#30 application references project team-c which does not exist
ErrorOccurred  application references project team-c which does not exist

Source-verified applicationset_controller.go: application references project %s which does not exist. An Application created directly that references a non-existent project also gets an InvalidSpecError (different wording; check actual output).

Symptom: When a new team onboards, the AppSet syncs before the AppProject; or the project file was renamed but metadata.name unchanged; or project the field is a template parameter whose argument is missing (it renders as an empty string).

Root cause: An Application must belong to an existing AppProject; the project is the prerequisite for all validation.

Diagnostic commands
argocd proj list
argocd appset generate ~/gitops-lab/argocd/appsets/teams.yaml -o json | jq -r '.[].spec.project' | sort -u
Fix

In App of Apps, use a wave so that the project comes before the AppSet: argocd/projects/*.yaml add argocd.argoproj.io/sync-wave: "-1"; or the project and AppSet are generated together from the same “team bootstrap” template.

Prevention and best practices
  • Fixed bootstrap order: project → repo / cluster credentials → AppSet / Application (Lesson 3 Module 2).
  • Do not make the project name an optional parameter; a missing value should produce an error (#27).

See Lesson 3 Module 2 App of Apps and bootstrap.

#31 there are no clusters with this name: lab2
InvalidSpecError  … there are no clusters with this name: lab2

Source-verified util/argo/argo.go: there are no clusters with this name: %s; in an AppSet it is wrapped as application destination spec is invalid: ….

Symptom:destination.name: lab2 Applications for argocd cluster list are invalid; the name actually displayed is kind-lab2 (argocd cluster add by default uses the kubeconfig context name); or the cluster Secret was not restored in the new Argo CD instance.

Root cause:destination.name Matching by the name field in the cluster Secret is exact; destination.server matching by URL. Only one of the two may be used.

Diagnostic commands
argocd cluster list
kubectl -n argocd get secret -l argocd.argoproj.io/secret-type=cluster -o jsonpath='{range .items[*]}{.metadata.name}{"\t"}{.data.name}{"\n"}{end}' | while read s n; do echo "$s $(echo "$n" | base64 -d)"; done
Fix
argocd cluster set kind-lab2 --name lab2            # or specify it at registration: argocd cluster add kind-lab2 --name lab2
Prevention and best practices
  • Make cluster registration declarative: cluster Secret (argocd.argoproj.io/secret-type: cluster, key name/server/config) is managed by Git + a secrets tool, and names follow a platform convention (lab2,prod-eu-1).
  • Labels on cluster Secrets are used by the Cluster generator to select (env: prod), do not rely on string matching of cluster names.
  • Related pitfall: the local cluster (in-cluster) by default has no cluster Secret, so no Cluster generator with a label selector will select it (official Generators-Cluster docs); when needed, declaratively create an in-cluster cluster Secret and add labels.

See Lesson 4 Module 5 Registering clusters and declarative cluster Secrets.

#32 lab2 cluster Unknown: dial tcp 127.0.0.1:41xxx: connect: connection refused (kind's kubeconfig address is unreachable from inside a Pod)
$ argocd cluster list
SERVER                     NAME  VERSION  STATUS   MESSAGE
https://127.0.0.1:41893    lab2           Unknown  … dial tcp 127.0.0.1:41893: connect: connection refused

Symptom: Registering the kind cluster with kubeconfig lab2, the CLI succeeds, but all applications deploying to lab2 are Unknown. Similar real-world production issues: the kubeconfig uses an API address reachable only from the office network, a private cluster's API endpoint, or traffic blocked by a firewall.

Root cause: The API address kind writes into the host kubeconfig is 127.0.0.1:random port (a port mapping on the host). In lab the cluster, argocd-application-controller runs and accesses 127.0.0.1 — which is its own Pod. The two kind clusters are on the same Docker network kind , so the internal address should be used https://lab2-control-plane:6443.

Diagnostic commands
kind get kubeconfig --name lab2 --internal | grep server
kubectl -n argocd exec sts/argocd-application-controller -- sh -c 'getent hosts lab2-control-plane || true'
argocd admin cluster stats -n argocd 2>/dev/null | head
    server: https://lab2-control-plane:6443
Fix
kind get kubeconfig --name lab2 --internal > /tmp/lab2-internal.kubeconfig
argocd cluster rm https://127.0.0.1:41893
argocd cluster add kind-lab2 --name lab2 --cluster-endpoint kube-public --yes     # Lesson 4 approach: use the cluster-info address in the kube-public namespace
# or: argocd cluster add kind-lab2 --name lab2 --kubeconfig /tmp/lab2-internal.kubeconfig --yes
# If the local CLI cannot resolve lab2-control-plane: switch to a declarative cluster Secret, with the internal address in server and the argocd-manager ServiceAccount's token and CA from lab2 in config
Prevention and best practices
  • Cluster addresses should follow the network where the controller runs; in production, the network path from the hub to spoke cluster APIs (private endpoints, VPN, firewalls) should be documented as a platform dependency and monitored argocd_cluster_connection_status.
  • argocd cluster add creates in the target cluster argocd-manager a ServiceAccount and grants cluster-admin by default (interview Q30 discusses least privilege).

See Lesson 4 Module 5,the Kubernetes course(kind networking).

#33 PermissionDenied: permission denied: applications, sync, team-a/podinfo-dev, sub: alice, iat: 2026-11-17T02:10:44Z
$ argocd app sync podinfo-dev
FATA[0000] rpc error: code = PermissionDenied desc = permission denied: applications, sync, team-a/podinfo-dev, sub: alice, iat: 2026-11-17T02:10:44Z

Source-verified util/rbac/rbac.go of EnforceErr: permission denied + : + resource, action, object, then append sub: <user identifier> and iat: <RFC3339>. Note: for an application that does not exist or that the user is not allowed to view, the API also uniformly returns permission denied, so as not to reveal whether the application exists (server/application/application.go comment).

Symptom: Developers can see the application but cannot sync; or CI's project token suddenly stops working; or a user was just added to a group but permissions do not change (the groups in the JWT are not refreshed until the next login —iat that is a troubleshooting clue).

Root cause: Casbin decision: subject (user / group / project role) → role → p, role, resource, action, project/object, allow|deny. If no allow matches, the request is denied; if a deny matches, deny takes precedence.

Diagnostic commands
argocd account get-user-info                                    # current identity and groups
argocd account can-i sync applications 'team-a/podinfo-dev'
argocd admin settings rbac can alice sync applications 'team-a/podinfo-dev' --namespace argocd   # offline check by an administrator
kubectl -n argocd get cm argocd-rbac-cm -o jsonpath='{.data.policy\.csv}'
Logged In: true
Username: alice
Groups: devs
no
Fix
data:
  policy.default: role:readonly
  scopes: '[groups, email]'
  policy.csv: |
    p, role:team-a-dev, applications, get,  team-a/*, allow
    p, role:team-a-dev, applications, sync, team-a/*, allow
    p, role:team-a-dev, logs, get, team-a/*, allow
    g, team-a-devs, role:team-a-dev
Prevention and best practices
  • Keep RBAC in Git, and in CI run regression tests with argocd admin settings rbac validate and a set of rbac can assertions (who can, who cannot).
  • Put team permissions in the AppProject's roles (managed with the project); global policy.csv should hold only platform roles.

See Lesson 4 Module 3 RBAC.

#34 SSO login succeeds but no applications are visible: groups are not mapped (scopes / groups claim / Dex sub change)
Logged In: true
Username: alice@example.com
Issuer: https://argocd.example.com/api/dex
Groups:

Official docs v3.0 upgrade notes: when using Dex SSO, policies based on Dex sub claims no longer apply; they should be changed to be based on federated_claims.user_id.

Symptom: UI login succeeds, but the application list is empty; policy.csv the one written in g, my-org:team-a, role:team-a-dev, but it does not take effect; after upgrading to v3, some policies written for users stop working.

Root cause:① the IdP does not return groups in the token (Entra ID needs the groups claim configured in the app registration, and large groups may return an “overage” reference instead of a list; Okta needs the groups scope); ②argocd-rbac-cm the scopes does not include groups (default [groups], someone changed it to [email]); ③ group name formats differ (the GitHub connector uses org:team, Entra uses object IDs); ④ changes to Dex user identifiers in v3.

Diagnostic commands
argocd account get-user-info
kubectl -n argocd get cm argocd-rbac-cm -o jsonpath='{.data.scopes}'; echo
kubectl -n argocd logs deploy/argocd-dex-server --tail=50 | grep -iE 'group|claim|error'
kubectl -n argocd logs deploy/argocd-server --tail=50 | grep -i 'permission denied'
Fix

First have the IdP return groups and use get-user-info to see them, then, based on what is seen,exact string write g rules; when authorizing individuals, use the identifier recommended for v3. Do not use policy.default: role:admin as a means of “fixing the problem first.”

Prevention and best practices
  • Always authorize by group, not by individual; keep group-to-role mappings in Git and review them.
  • For large Entra ID groups, use app roles or group filtering to avoid group overage (Lesson 4 Module 4).

See Lesson 4 Module 4 SSO.

#35 After upgrading to v3, developers cannot see the LOGS tab in the Pod view of the UI (log RBAC enforced by default)
permission denied: logs, get, team-a/podinfo-dev, sub: alice, iat: …

Official docs v2.14 → 3.0 upgrade notes: server.rbac.log.enforce.enable has been removed, and log RBAC is enforced by default; users without an explicit logs, get permission cannot see the logs tab. Users who have not set policy.default, and have not enabled that flag, are affected.

Symptom: After the upgrade, developers report that the “logs button is gone”; on call, they cannot view logs through Argo CD.

Root cause: In v2, applications, get implicitly granted logs permission; in v3, logs is a separate resource.

Diagnostic commands
argocd account can-i get logs 'team-a/*'
kubectl -n argocd get cm argocd-cm -o jsonpath='{.data.server\.rbac\.log\.enforce\.enable}'; echo
Fix
p, role:team-a-dev, logs, get, team-a/*, allow          # recommended: add per role (least privilege)
# quick but broad: p, role:global-log-viewer, logs, get, */*, allow  + policy.default: role:global-log-viewer
Prevention and best practices
  • Before upgrading, check each item in the upgrade notes' “Detection” section (log RBAC, fine-grained inheritance #36, tracking method #50, old repository configuration #4, metric removal).
  • Logs may contain sensitive information; grant access per project rather than opening it globally.

See Lesson 4 Module 3,Lesson 7 Module 7 Upgrades.

#36 In v3, a user has applications update/delete permission but cannot delete a Pod (fine-grained permissions no longer inherit to child resources)
permission denied: applications, delete/Pod/podinfo-dev/podinfo-7d9c…, team-a/podinfo-dev, sub: alice, iat: …

Official docs v3.0 upgrade notes: update/delete applies only to the Application itself; to grant operations on managed resources, add new update/*,delete/* policies; you can set server.rbac.disableApplicationFineGrainedRBACInheritance: "false" to restore v2 behavior. RBAC docs example: p, example-user, applications, delete/*/Pod/*/*, default/prod-app, allow.

Symptom: An on-call engineer clicks “Delete Pod” in the UI to have it recreated and is denied; or running the resource action (restart) fails.

Root cause: v3 authorizes “modifying the Application” and “modifying the resources it manages” separately, to prevent people with application edit rights from deleting cluster resources at will.

Diagnostic commands
argocd admin settings rbac can alice 'delete/*/Pod/*/*' applications 'team-a/podinfo-dev' --namespace argocd
kubectl -n argocd get cm argocd-cm -o jsonpath='{.data.server\.rbac\.disableApplicationFineGrainedRBACInheritance}'; echo
Fix
p, role:team-a-oncall, applications, delete/*/Pod/*/*, team-a/*, allow     # allow deleting Pods only
p, role:team-a-oncall, applications, action/apps/Deployment/restart, team-a/*, allow
Prevention and best practices
  • Grant the minimum based on “what on-call needs”: delete Pods and restart Deployments, rather than update/*.
  • Note the RBAC docs' warning: when Argo CD matches globs, it does not treat / as a separator,delete/*/Pod/* so such patterns may match more broadly than you expect; be especially careful with deny rules.

See Lesson 4 Module 3.

#37 resource :Namespace is not permitted in project team-a / namespace kube-system is not permitted in project 'team-a'
one or more synchronization tasks are not valid
… resource :Namespace is not permitted in project team-a
… namespace kube-system is not permitted in project 'team-a'

Source-verified controller/sync.go: resource %s:%s is not permitted in project %s (the core group is empty, so it is shown as :Namespace),namespace %v is not permitted in project '%s'; one or more synchronization tasks are not valid comes from sync_context.go.

Symptom: The team's chart includes Namespace, ClusterRole, CRD or ValidatingWebhookConfiguration; or the manifests hard-code namespace: kube-system. The sync fails as a whole during validation,and not a single resource is applied.

Root cause: When the project's clusterResourceWhitelist is empty, all cluster-scoped resources are forbidden; namespaceResourceBlacklist/Whitelist governs namespace-scoped kinds; explicit namespaces in the manifests must likewise pass the destinations check.

Diagnostic commands
argocd proj get team-a | grep -iE 'cluster|namespace'
argocd app manifests podinfo-dev | yq 'select(.metadata.namespace == null) | .kind' | sort | uniq -c
Fix

Move cluster-level resources into a platform application (platform project); the team's chart disables creating Namespace / CRD via values. When truly needed, the platform team grants exactly what is required:

spec:
  clusterResourceWhitelist:
  - {group: '', kind: Namespace}          # allow only the kinds needed; do not use {group: '*', kind: '*'}
Reproduction lab
mkdir -p ~/gitops-lab/lab8/pb37 && kubectl create ns lab8-pb37-extra --dry-run=client -o yaml > ~/gitops-lab/lab8/pb37/ns.yaml
cd ~/gitops-lab && git add lab8 && git commit -qm "lab8: pb37" && git push -q
l8_app pb37 lab8/pb37 --sync-option CreateNamespace=true && argocd app sync lab8-pb37; l8_why pb37 | grep -i permitted

See Lesson 4 Module 2 Sources, destinations and cluster resource allowlist.

#38 application 'podinfo-dev' in namespace 'team-a' is not permitted to use project 'team-a' (Applications in any namespace)
application 'podinfo-dev' in namespace 'team-a' is not permitted to use project 'team-a'

Source-verified util/argo/argo.go: application '%s' in namespace '%s' is not permitted to use project '%s'.

Symptom: To let teams self-serve, an Application is placed in the team's own namespace team-a : either it is not reconciled at all (not visible in the UI), or the error above is reported.

Root cause: Two layers of allowance are needed: ① the control plane allows these namespaces: argocd-cmd-params-cm in application.namespaces: team-a, team-b (both server and application-controller must be restarted to take effect); ② the project allows Applications from these namespaces: the AppProject's spec.sourceNamespaces: [team-a]. If layer ① is missing, the application is ignored; if layer ② is missing, this error is reported.

Diagnostic commands
kubectl -n argocd get cm argocd-cmd-params-cm -o jsonpath='{.data.application\.namespaces}'; echo
kubectl -n argocd get appproject team-a -o jsonpath='{.spec.sourceNamespaces}'; echo
argocd app list -A 2>/dev/null | head || argocd app list --app-namespace team-a
Fix
configs:                        # Helm values
  params:
    application.namespaces: "team-a, team-b"
# AppProject team-a:
# spec:
#   sourceNamespaces: [team-a]
Prevention and best practices
  • An Application in a team namespace can only use a project that allows it — this is precisely the feature's security boundary; do not put the default project into sourceNamespaces.
  • The RBAC object format becomes project/namespace/application (such as team-a/team-a/podinfo-dev), and policies must be adjusted accordingly.
  • ApplicationSet also supports any namespace (docs: Appset-Any-Namespace), and its scope must be covered by the Application's allowed namespaces.

See Lesson 4 Module 7 Applications in any namespace.

One reconciliation of the ApplicationSet controller: errors appear in the AppSet's Condition GeneratorList/Git/Cluster/PR#29 polling Template renderinggoTemplate#27 missing key ValidationDuplicate names · project · cluster#26 #30 #31 Write per policycreate/update/delete#28 accidental deletion ApplicationHanded to the application controllerProject / RBAC validation Authorization of one API request (#33–#36)Token (local account / SSO JWT / project token) → sub and groups (scopes) → g rules map roles (including project roles)→ p rules: resource (applications / logs / exec / clusters / repositories / projects …) + action (get / sync / update / delete / update/* / delete/*/Pod/*/* / override / action/…) + object (project/application)→ any deny match rejects; an allow match permits; otherwise check policy.defaultDenial message: permission denied: resource, action, object, sub: …, iat: … (non-existent applications also return permission denied)
Figure 3-1 AppSet controls “what is generated”; projects and RBAC control “what is allowed”

RBAC decision simulator

Choose a request, click “Evaluate,” and step through “subject and groups → role → policy match → deny first → default role.” The policies come from the examples below Figure 3-1 on this page policy.csv (the rule format matches the Argo CD RBAC docs; the evaluation process is simplified for teaching; for complex globs, defer to argocd admin settings rbac can for the authoritative behavior).

policy.default: role:readonly
p, role:team-a-dev, applications, get,  team-a/*, allow
p, role:team-a-dev, applications, sync, team-a/*, allow
p, role:team-a-dev, logs, get, team-a/*, allow
p, role:team-a-dev, applications, sync, team-a/podinfo-prod, deny
p, role:team-a-oncall, applications, delete/*/Pod/*/*, team-a/*, allow
g, team-a-devs, role:team-a-dev
g, team-a-oncall, role:team-a-oncall
$ Waiting to evaluate…
Environment Same as Module 0; Lab 3-B requires a kind cluster lab2; Lab 3-C modifies argocd-cm / argocd-rbac-cm— back up first. Output is an example.

Lab 3-A: duplicate AppSet names and preview (#26, #27)

cat > /tmp/pb26.yaml <<'EOF'
apiVersion: argoproj.io/v1alpha1
kind: ApplicationSet
metadata: {name: lab8-pb26, namespace: argocd}
spec:
  goTemplate: true
  goTemplateOptions: ["missingkey=error"]
  generators:
  - list:
      elements: [{env: a}, {env: b}]
  template:
    metadata: {name: 'lab8-pb26', labels: {lab8: "true"}}
    spec:
      project: lab8
      source: {repoURL: 'https://github.com/<you>/gitops-lab', targetRevision: lab8, path: lab8/pb07}
      destination: {server: https://kubernetes.default.svc, namespace: 'lab8-pb26-{{.env}}'}
EOF
argocd appset generate /tmp/pb26.yaml -o json | jq -r '.[].metadata.name'
lab8-pb26
lab8-pb26
kubectl apply -f /tmp/pb26.yaml; sleep 5
kubectl -n argocd get applicationset lab8-pb26 -o jsonpath='{range .status.conditions[*]}{.type}={.message}{"\n"}{end}' | grep -i duplicate
ErrorOccurred=ApplicationSet lab8-pb26 contains applications with duplicate name: lab8-pb26
Change the name to 'lab8-pb26-{{.env}}' and re-apply; then change it to {{.envv}} observe the failed to execute go template. Finally, kubectl -n argocd delete applicationset lab8-pb26, observe the Applications it generated being deleted (#28).

Lab 3-B: kind cluster address (#31, #32)

argocd cluster add kind-lab2 --yes 2>&1 | tail -1          # using the host kubeconfig (127.0.0.1)
sleep 20; argocd cluster list
SERVER                    NAME       VERSION  STATUS   MESSAGE
https://127.0.0.1:41893   kind-lab2           Unknown  … connection refused
argocd cluster rm https://127.0.0.1:41893 --yes 2>/dev/null || argocd cluster rm https://127.0.0.1:41893
argocd cluster add kind-lab2 --name lab2 --cluster-endpoint kube-public --yes   # consistent with Lesson 4 (--cluster-endpoint can be kubeconfig / kube-public / internal)
argocd cluster list

kind's kube-public/cluster-info records the API address inside the container network (https://lab2-control-plane:6443, check actual output). You can also register with the kind get kubeconfig --name lab2 --internal generated kubeconfig, or use the declarative cluster Secret from Lesson 4. When done, applications such as podinfo are placed in the project according to the Lesson 4 convention platform, and team applications are in team-a / team-b.

Lab 3-C: RBAC (#33, #35) and cleanup

kubectl -n argocd patch cm argocd-cm --type merge -p '{"data":{"accounts.alice":"login"}}'
argocd account update-password --account alice --new-password 'Alice-Lab8!' --current-password "$ADMIN_PASS"
kubectl -n argocd patch cm argocd-rbac-cm --type merge -p '{"data":{"policy.csv":"p, alice, applications, get, lab8/*, allow\n"}}'
argocd admin settings rbac can alice sync applications 'lab8/lab8-pb07' --namespace argocd
argocd admin settings rbac can alice get logs 'lab8/lab8-pb07' --namespace argocd
No
No
Cleanup:
kubectl apply -f ~/lab8-cm-backup.yaml; l8_clean

Teaching videos (titles and channels verified via YouTube oEmbed)

▶
Multi-cluster, multi-apps, multi-value deployments using Argo CD Application Sets - Kostis Kapelonis — CNCF [Cloud Native Computing Foundation]
English · ApplicationSet and multi-cluster (#26–#31)
▶
🔐 ArgoCD User Management & RBAC Explained 👥 | Create Users, Passwords & Okta SSO 🌐 — Ashok Kumar
English · local accounts, RBAC and SSO (#33, #34)
▶
Argo CD Tutorial: App of Apps in 8 Minutes — Akuity
English · bootstrap order (#30)

Third-party videos may be based on v2 (for example, they do not cover v3's log RBAC and fine-grained permissions); defer to this lesson and the official docs. No verified video was found that specifically covers kind multi-cluster networking and troubleshooting Applications in any namespace; storyboard:

Shot 1 (0:00) argocd appset generate Output two same-name applications; after apply, the AppSet's ErrorOccurred.
Shot 2 (0:50) argocd cluster list Show that 127.0.0.1 is unreachable; kind get kubeconfig --internal re-register.
Shot 3 (1:40) rbac can Verify item by item; after adding logs, get the logs tab appears in the UI.

Official docs

or get ≥ 70% in the “Quiz”

Module 4 · Part A: Secrets, delivery, performance and upgrades (issues 39–50)

24:00 – 30:00 · Sealed Secrets, ESO, SOPS + CMP, render timeouts and cached errors, sync windows, Rollouts, Image Updater, Notifications, controller capacity, Git polling, v3 / 3.3+ upgrades
6 minEncrypt → deliver → scale → upgrade12 issues
Learning objectives
  • Be able to tell who decrypts in the secrets chain: Sealed Secrets is decrypted by the in-cluster controller (Argo CD only syncs SealedSecret); ESO is pulled by the in-cluster operator from the external secret store (Argo CD only syncs ExternalSecret); SOPS + CMP is decrypted by a Repo Server plugin (plaintext passes through Argo CD's rendering and caching, the highest risk).
  • Know the timeout levels in the rendering path: CMP / tool execution timeout ARGOCD_EXEC_TIMEOUT (default 90 seconds), the controller's wait for repo-server's controller.repo.server.timeout.seconds (default 60 seconds), and render failures get cached (Manifest generation error (cached)).
  • Know the controller's main capacity parameters: controller.status.processors (default 20),controller.operation.processors (default 10),controller.kubectl.parallelism.limit (default 20), sharding algorithm (default legacy),timeout.reconciliation (default 120 seconds + 60 seconds jitter), and the key changes when upgrading to v3 / 3.3 / 3.5 / 3.6.

Enter keywords (such as decrypt,already exists,SecretSyncedError,plugin,cached,deadline,sync window,Paused,Image Updater,notification,OOM,rate limit,upgrade) to filter; click a row to jump to the details.

#39 SealedSecret does not generate a Secret: Failed to unseal: no key could decrypt secret
$ kubectl -n podinfo-prod describe sealedsecret db-cred | tail -3
Events:
  Type     Reason           Age  From            Message
  Warning  ErrUnsealFailed  12s  sealed-secrets  Failed to unseal: no key could decrypt secret (password)

Official source Sealed Secrets v0.41.2: event reason ErrUnsealFailed, message Failed to unseal: %v, inner no key could decrypt secret (pkg/crypto/crypto.go).

Symptom: In Argo CD the SealedSecret shows Synced, but the corresponding Secret does not exist (or has not been updated), and Pods that depend on it report secret "db-cred" not found; common causes: ① encrypted in the dev cluster with the dev certificate and copied to prod; ② the SealedSecret's name or namespace was changed; ③ the cluster was rebuilt, the controller generated a new key pair, and the old private key was not backed up.

Root cause: By default, the strict scope binds the namespace and name into the ciphertext; each cluster's controller has its own private key (by default a new key is added every 30 days, and old keys are kept for decryption).

Diagnostic commands
kubectl -n podinfo-prod get sealedsecret db-cred -o jsonpath='{.status.conditions}' | jq
kubectl -n kube-system get secret -l sealedsecrets.bitnami.com/sealed-secrets-key --sort-by=.metadata.creationTimestamp
kubeseal --controller-namespace kube-system --fetch-cert | openssl x509 -noout -fingerprint -sha256
Fix
kubeseal --controller-namespace kube-system --format yaml --namespace podinfo-prod --name db-cred < db-cred.secret.yaml > db-cred.sealed.yaml   # re-encrypt with the target cluster's certificate
# Cluster rebuilt: restore the old private key Secret from backup into kube-system and restart the controller
Prevention and best practices
  • Back up the private key (stored encrypted in a secrets vault) is the lifeline of Sealed Secrets; DR drills include “restore the private key on a new cluster.”
  • Keep one set of ciphertexts per environment, with the directory structure reflecting the cluster: apps/podinfo/overlays/prod/sealed/.

See Lesson 5 Module 4 Sealed Secrets.

#40 Resource "db-cred" already exists and is not managed by SealedSecret
Warning  ErrUpdateFailed  sealed-secrets  Resource "db-cred" already exists and is not managed by SealedSecret

Official source controller.go: Resource %q already exists and is not managed by SealedSecret.

Symptom: Migrating from a “manually created Secret” to Sealed Secrets: the SealedSecret has synced, but the Secret still holds the old value.

Root cause: The controller only updates Secrets it created itself (ownerReference points to the SealedSecret), and does not overwrite an existing Secret with the same name, so as not to break data managed by others.

Diagnostic commands
kubectl -n podinfo-prod get secret db-cred -o jsonpath='{.metadata.ownerReferences}{"\n"}{.metadata.annotations}{"\n"}'
Fix

Two approaches: delete the old Secret so the controller recreates it (brief absence; do it in a maintenance window); or add an annotation to the old Secret sealedsecrets.bitnami.com/managed: "true" so the controller takes it over (follow the Sealed Secrets docs).

Prevention and best practices
  • Migration checklist: list existing Secrets → encrypt → take over → verify → remove the manual process.
  • Argo CD should not manage a plaintext Secret of the same name in Git at the same time (that is also the shared-resource problem in #24).

See Lesson 5 Module 4.

#41 ExternalSecret status SecretSyncedError, application Degraded / or defaults filled in by ESO cause OutOfSync
$ kubectl -n podinfo-prod get externalsecret db-cred
NAME      STORETYPE            STORE        REFRESH INTERVAL   STATUS              READY
db-cred   ClusterSecretStore   azure-kv     1h                 SecretSyncedError   False

Official source ESO apis/externalsecrets/v1: ConditionReasonSecretSyncedError = "SecretSyncedError". This lesson uses API version external-secrets.io/v1.

Symptom: An entry in the external secret store was renamed, its permissions (Workload Identity binding) expired, or the SecretStore's authentication config is wrong; or the ExternalSecret syncs normally but Argo CD stays OutOfSync (ESO's admission / defaulting fills in fields in the spec).

Root cause: Argo CD only puts the ExternalSecret object into the cluster; fetching is done by ESO, and errors appear in the status of the ExternalSecret / SecretStore. Default-value differences belong to the #14 category.

Diagnostic commands
kubectl -n podinfo-prod describe externalsecret db-cred | sed -n '/Status:/,$p' | head -20
kubectl get clustersecretstore azure-kv -o jsonpath='{.status.conditions}' | jq
argocd app diff podinfo-prod | grep -A3 ExternalSecret
Fix
  • Authentication: fix the SecretStore's identity (for AKS Workload Identity see AKS course); entries: fix remoteRef.key.
  • Default-value differences: enable Server-Side Diff, or configure ignoreDifferences on the ExternalSecret.
Prevention and best practices
  • Write a custom health check for ExternalSecret (if the built-in check is insufficient), so that fetch failures show up as Degraded applications and trigger notifications.
  • “Rotation” in the secrets store must be paired with reloading the application (a rolling restart or a reloader).

See Lesson 5 Module 5 External Secrets Operator.

#42 could not find plugin supporting the given repository (SOPS / custom CMP sidecar)
ComparisonError  Failed to load target state: failed to generate manifest for source 1 of 1: rpc error: code = Unknown desc = … could not find plugin supporting the given repository

Source-verified util/app/discovery/discovery.go: could not find plugin supporting the given repository (when there is an inner error it is …: %w).

Symptom: A Config Management Plugin for SOPS decryption was written (as a sidecar), and the application specifies plugin: {} or plugin: {name: sops-kustomize}, yet it still reports that the plugin cannot be found.

Root cause (common):① the sidecar container does not use /var/run/argocd/argocd-cmp-server as its entrypoint, or does not mount /var/run/argocd and the plugin configuration; ②plugin.yaml the discover rule (fileName / find.glob) does not match the files in the repo; ③ the name written in the application does not match the plugin name — a plugin name with a version number is <name>-<version>; ④ the sidecar runs as root or the image lacks the tool, so startup fails.

Diagnostic commands
kubectl -n argocd get pod -l app.kubernetes.io/name=argocd-repo-server -o jsonpath='{.items[0].spec.containers[*].name}'; echo
kubectl -n argocd logs deploy/argocd-repo-server -c sops-kustomize --tail=30
kubectl -n argocd logs deploy/argocd-repo-server -c repo-server --tail=50 | grep -i plugin
Fix
apiVersion: argoproj.io/v1alpha1
kind: ConfigManagementPlugin
metadata: {name: sops-kustomize}
spec:
  discover:
    find:
      glob: "**/*.enc.yaml"
  generate:
    command: [sh, -c, "kustomize build --enable-alpha-plugins --enable-exec ."]
Prevention and best practices
  • CMP lets plaintext secrets enter the Repo Server's rendered output and the Redis cache, and makes them visible to anyone who can read application manifests (argocd app manifests) — if you can use ESO / Sealed Secrets, do not use SOPS-in-CMP.
  • Pin the plugin image version; the sidecar runs as non-root (UID 999); plugin commands are also subject to ARGOCD_EXEC_TIMEOUT constraints (#43).

See Lesson 5 Module 6 SOPS and Config Management Plugin.

#43 Manifest generation error (cached): … context deadline exceeded (render timeout, error cached)
ComparisonError  Failed to load target state: failed to generate manifest for source 1 of 1: rpc error: code = Unknown desc = Manifest generation error (cached): `helm dependency build` failed timeout after 1m30s

Source-verified reposerver/repository/repository.go: cachedManifestGenerationPrefix = "Manifest generation error (cached)".Official docs CMP commands are subject to ARGOCD_EXEC_TIMEOUT a constraint, default 90 seconds; controller.repo.server.timeout.seconds default 60.

Symptom: Large Helm charts (many dependencies, pulled from the internet), huge Kustomize trees, and slow CMPs that occasionally time out; after a fix, the same error is still reported — with (cached).

Root cause: Repo Server caches consecutive failures of rendering, to avoid repeatedly running expensive renders that are destined to fail; during the cache period, even if the root cause has been eliminated, the cached error is returned directly. Timeouts exist at several layers: tool execution (ARGOCD_EXEC_TIMEOUT), the controller → repo-server gRPC timeout, and repo-server concurrency limits reposerver.parallelism.limit that cause queuing.

Diagnostic commands
argocd app get myapp --hard-refresh                 # hard refresh: bypass the manifest cache and re-render
kubectl -n argocd logs deploy/argocd-repo-server --since=15m | grep -iE 'timeout|deadline|took'
kubectl -n argocd get cm argocd-cmd-params-cm -o yaml | grep -E 'repo.server.timeout|parallelism'
Fix
configs:
  params:
    controller.repo.server.timeout.seconds: "180"
    server.repo.server.timeout.seconds: "180"
repoServer:
  env:
  - {name: ARGOCD_EXEC_TIMEOUT, value: "180s"}
  replicas: 2
Prevention and best practices
  • Fixing the root cause matters more than raising timeouts: vendor the Helm dependencies into the repo (charts/ + Chart.lock), avoid accessing the internet during rendering; split huge monolithic applications.
  • Monitor argocd_repo_pending_request_total the rendering-duration histogram (Lesson 7 Module 4).

See Lesson 7 Module 3 Repo Server: caching, timeouts and manifest generation.

#44 PermissionDenied: cannot sync: blocked by sync window / Sync operation blocked by sync window
$ argocd app sync podinfo-prod
FATA[0000] rpc error: code = PermissionDenied desc = cannot sync: blocked by sync window
# During auto-sync, the operation status message is: Sync operation blocked by sync window

Source-verified server/application/application.go: cannot sync: blocked by sync window; controller/sync.go: Sync operation blocked by sync window.

Symptom: On Friday evening, while fixing a production issue, a manual sync is rejected; or after a change freeze ends, some applications do not auto-sync.

Root cause: The AppProject's syncWindows (allow / deny, cron + duration, matched by application / namespace / cluster). Deny windows take precedence; manualSync: true permits manual sync within the window.

Diagnostic commands
argocd proj windows list team-a
argocd app get podinfo-prod | grep -i window
Fix

For emergency changes, follow the “break-glass” process: the platform team temporarily adds manualSync: true (leaving a review record) in Git, or temporarily disables the window after approval; do not directly kubectl apply bypass Argo CD (self-healing will revert it later).

Prevention and best practices
  • Freeze windows and time zones: timeZone set the field explicitly to avoid UTC errors; window changes themselves go through Git.
  • Write a break-glass runbook: who approves, how to temporarily allow, how to backfill Git (interview Q6, Q45).

See Lesson 6 Module 6 Sync windows and change freezes.

#45 Rollout stuck at Paused (Suspended), or Degraded after an AnalysisRun fails; the new version in Git has “neither gone live nor been rolled back”
Name:            podinfo
Status:          ✖ Degraded
Message:         RolloutAborted: Rollout aborted update to revision 5: Metric "success-rate" assessed Failed …
Strategy:        Canary
  Step:          1/6
  SetWeight:     0

Symptom:① a canary step has an indefinite pause: {}, nobody runs promote, and the application shows Suspended; ② analysis fails, the Rollout automatically aborts and returns to the stable version, the application is Degraded, but Git still has the new version — Argo CD shows Synced, because the Rollout's spec does match Git.

Root cause: Rollouts manages “how to go live”; Argo CD manages “what is desired.” After an abort, the desired state (Git) differing from the running version is by design: a person or automation must change Git back (or, after a fix, advance to a new version).

Diagnostic commands
kubectl argo rollouts get rollout podinfo -n podinfo-prod
kubectl -n podinfo-prod get analysisrun --sort-by=.metadata.creationTimestamp | tail -3
argocd app get podinfo-prod | grep -E 'Rollout|Suspended|Degraded'
Fix
kubectl argo rollouts promote podinfo -n podinfo-prod      # after confirming, advance the paused step (the Argo CD UI also has a resume action)
cd ~/gitops-lab && git revert --no-edit HEAD && git push  # analysis failed: roll back Git so the desired state matches the stable version
Prevention and best practices
  • Give paused steps duration a duration, or let analysis advance them automatically; indefinite pauses are only for production that needs a manual gate, and should be paired with notifications.
  • Notifications subscription on-health-degraded; include “automatically open a rollback PR after an abort” in the workflow of the promotion tool (Kargo, etc.).
  • Current Rollouts version v1.10.2 (as of the verification date); Argo CD has built-in Rollout health checks and resource actions such as resume / abort.

See Lesson 6 Module 2 Argo Rollouts,Module 3 AnalysisTemplate.

#46 Image Updater does not update the image: no ImageUpdater CR / the application is plain YAML / write-back to Git fails
New image 6.17.0 pushed → 30 minutes later podinfo-dev is still 6.16.0
argocd-image-updater logs: … could not … push … / … not supported for application …

Official docs Image Updater README (v1.5.0): uses a dedicated ImageUpdater CR defines tracking and update rules; only supports Kustomize, Helm or Plugin built applications; plain YAML applications are not supported; updates are done via Argo CD parameter overrides or commits to Git; the README still warns “not recommended for critical production workloads.”

Symptom: Following an old blog, an annotation was added to the Application argocd-image-updater.argoproj.io/image-list that has no effect in v1.x; or the application is a plain YAML directory; or git the write-back method lacks push credentials / the branch is protected.

Root cause: The v1.x configuration model changed to CRs; writing back to Git requires credentials with push permission, and is subject to branch protection rules.

Diagnostic commands
kubectl get crd | grep -i imageupdater
kubectl -n argocd get imageupdaters.argocd-image-updater.argoproj.io 2>/dev/null || kubectl get imageupdater -A
kubectl -n argocd logs deploy/argocd-image-updater-controller --tail=80 2>/dev/null | grep -iE 'error|denied|skip'
argocd app get podinfo-dev -o json | jq -r '.status.sourceType'
Fix
  • Create an ImageUpdater resource for the application (check fields against the CRD and docs for your installed version); change podinfo to a Kustomize overlay (images:) or to Helm values.
  • Write back to Git: use a GitHub App / deploy key and allow the bot to push directly to the designated branch, or write back to a separate branch and merge it via PR.
Prevention and best practices
  • Auto-update only dev / preview environments; promote staging / prod via PR (Lesson 6 Module 7; Kargo v1.12.6 is one option).
  • Use semver constraints or digests for the image tag policy, to avoid latest.

See Lesson 6 Module 4 Argo CD Image Updater.

#47 A deployment failed but no notification was received (Notifications subscription / triggers / secrets)
podinfo-prod Degraded for 20 minutes, no messages in the Slack channel; no sent records in the argocd-notifications-controller logs

Symptom: Notifications is installed but has no effect; or only some applications send notifications; or dev notifications flood the channel.

Root cause: Three things are needed at the same time: ①argocd-notifications-cm the service (service.slack),triggers (trigger.on-health-degraded), and templates; ②argocd-notifications-secret token in subscription annotation, for example notifications.argoproj.io/subscribe.on-health-degraded.slack: podinfo-alerts. If any one of them is missing, nothing is sent.

Diagnostic commands
kubectl -n argocd get application podinfo-prod -o jsonpath='{.metadata.annotations}' | jq 'with_entries(select(.key|startswith("notifications")))'
argocd admin notifications trigger get -n argocd 2>/dev/null | head
argocd admin notifications template notify app-health-degraded podinfo-prod --recipient slack:podinfo-alerts -n argocd
kubectl -n argocd logs deploy/argocd-notifications-controller --tail=50
Fix

Fill in the missing links; it is recommended to add AppProject on the project so that all applications in the project inherit it and none is missed one by one.

Prevention and best practices
  • Only notify on events that need action (Degraded, sync failure, successful deploy to prod); downgrade dev to summaries; triggers use oncePer to avoid duplicates.
  • Notifications are not monitoring: also alert using Prometheus metrics (the Prometheus & Grafana course).

See Lesson 6 Module 5 Notifications.

#48 argocd-application-controller OOMKilled / reconciliation getting slower (applications take minutes to update after Refresh)
$ kubectl -n argocd get pod argocd-application-controller-0
NAME                              READY   STATUS      RESTARTS      AGE
argocd-application-controller-0   0/1     OOMKilled   7 (2m ago)    3d

Symptom: After the number of applications grew from 200 to 2000 and several large clusters were newly onboarded (many CRDs, Events, ReplicaSet history), the controller repeatedly OOMs; statuses in the UI are not updated for long periods; syncs queue up.

Root cause: The controller maintains, for each managed cluster, one watch cache of all resource types (by default it caches almost all resources in the cluster, not just managed ones); memory is proportional to cluster size; reconciliation work is done by a limited number of processors (status 20, operation 10); a single StatefulSet replica handles all clusters.

Diagnostic commands
kubectl -n argocd top pod -l app.kubernetes.io/name=argocd-application-controller
argocd admin cluster stats -n argocd                    # resource count, API count and cache status per cluster
argocd admin cluster shards -n argocd 2>/dev/null
kubectl -n argocd logs sts/argocd-application-controller --tail=100 | grep -iE 'reconciliation|took|queue'
Fix
controller:
  replicas: 3                                    # sharding: assign clusters to different replicas
  resources: {requests: {memory: 2Gi}, limits: {memory: 4Gi}}
configs:
  params:
    controller.sharding.algorithm: round-robin   # default legacy (hash by cluster ID); round-robin is Alpha, follow feature-maturity
    controller.status.processors: "50"
    controller.operation.processors: "25"
  cm:
    resource.exclusions: |                       # do not cache unneeded resource types
      - apiGroups: ["events.k8s.io", ""]
        kinds: ["Event"]
        clusters: ["*"]
Prevention and best practices
  • Sharding assigns by “cluster”: a single very large cluster cannot be split across multiple shards; in that case consider one Argo CD per cluster or agent mode (Lesson 4 Module 6).
  • Since v3.0 the default resource.exclusions already excludes a batch of frequently changing resources (upgrade notes “Default resource.exclusions configurations”); when customizing, do not overwrite the defaults.
  • Capacity metrics: argocd_app_reconcile (histogram),workqueue_depth, controller memory; do capacity planning by application count / cluster resource count (interview Q34).

See Lesson 7 Module 2 Application Controller sharding and performance tuning.

#49 GitHub API rate limit exceeded / Git server overwhelmed by Argo CD polling (thousands of applications × every 3 minutes)
… 429 Too Many Requests / API rate limit exceeded for installation ID …
GitLab: argocd-repo-server's git ls-remote requests account for 60% of all traffic

Official docs argocd-cm Example: timeout.reconciliation: 120s,timeout.reconciliation.jitter: 60s; the Git generator polls every 3 minutes by default.

Symptom: The PR generator / SCM Provider generator triggers GitHub API rate limiting and preview environments stop updating; self-hosted GitLab load rises; in a monorepo, any commit causes all applications to re-render.

Root cause: Each application periodically ls-remote resolves its revision; in a monorepo, one commit changes the revision of all applications → everything re-renders. The PR / SCM generators call the hosting platform's API.

Diagnostic commands
kubectl -n argocd get cm argocd-cm -o jsonpath='{.data.timeout\.reconciliation}{" "}{.data.timeout\.reconciliation\.jitter}'; echo
kubectl -n argocd port-forward deploy/argocd-repo-server 8084:8084 & sleep 1; curl -s localhost:8084/metrics | grep -E '^argocd_git_request_total' | head   # 8084 is the repo-server metrics port
Fix
  • Configure a webhook (Git push → immediate refresh), and then you can relax the polling interval (for example timeout.reconciliation: 300s).
  • monorepo: on the application, add argocd.argoproj.io/manifest-generate-paths: . (or a specific path), so re-rendering happens only when relevant paths change.
  • The PR generator uses GitHub App authentication (higher quota), and adjust requeueAfterSeconds.
Prevention and best practices
  • Monitor argocd_git_request_total, and the GitHub App's remaining quota (the ApplicationSet controller provides GitHub rate-limit metrics).
  • When multiple Argo CD instances share one Git server, coordinate polling and webhooks centrally.

See Lesson 7 Module 3,Lesson 3 Module 6.

#50 Upgrade incident: The CustomResourceDefinition "applicationsets.argoproj.io" is invalid: metadata.annotations: Too long / after switching to annotation tracking in v3, resources became orphans
The CustomResourceDefinition "applicationsets.argoproj.io" is invalid: metadata.annotations: Too long: may not be more than 262144 bytes

Official docs 3.2 → 3.3 upgrade notes: the ApplicationSet CRD exceeds the size limit for client-side apply, so you must use kubectl apply --server-side --force-conflicts to upgrade; when Argo CD self-manages, enable in the Application ServerSideApply=true; use helm upgrade to upgrade are not affected. 2.14 → 3.0 upgrade notes: the default changed to annotation tracking; if the first sync after switching includes deleting resources, Argo CD may not recognize that resource and will not delete it (an orphan), so it is recommended to sync all applications once after upgrading.

Symptom:① using kubectl apply -f install.yaml or upgrading to 3.3+ by Argo CD itself (SSA not enabled) causes CRD updates to fail, and old and new components run side by side; ② a few weeks after upgrading to v3, a resource was deleted from Git but remained in the cluster.

Root cause: See above; in addition, v3 ignores by default status field differences; ignoreDifferences is also used to ignore update events, so a few teams that rely on the old behavior will see the “difference disappear.”

Diagnostic commands
kubectl get cm argocd-cm -n argocd -o jsonpath='{.data.application\.resourceTrackingMethod}'; echo     # empty or label means v2 label tracking
kubectl get applications.argoproj.io -A -o json | jq -r '.items[] | select(.spec.syncPolicy.syncOptions[]? == "ApplyOutOfSyncOnly=true") | .metadata.name'
kubectl get crd applicationsets.argoproj.io -o jsonpath='{.metadata.annotations}' | wc -c
kubectl -n argocd get deploy,sts -o custom-columns=NAME:.metadata.name,IMAGE:.spec.template.spec.containers[0].image

The first two commands come from the “Detection” section of the 2.14 → 3.0 upgrade notes.

Fix
# For 3.3+, upgrade using manifests:
kubectl apply -n argocd --server-side --force-conflicts -f https://raw.githubusercontent.com/argoproj/argo-cd/v3.6.1/manifests/install.yaml
# This lesson's Helm approach:
helm upgrade argocd argo/argo-cd -n argocd --version 10.18.0 -f ~/gitops-lab/bootstrap/argocd-values.yaml
# After upgrading to v3: sync all applications once (applications using ApplyOutOfSyncOnly must sync once without that option), so the tracking annotations are written
Prevention and best practices
  • Upgrade one minor version at a time and read every upgrade note (2.14→3.0, 3.0→3.1 … 3.5→3.6); rehearse first on the staging Argo CD instance; before upgrading, argocd admin export back up (Lesson 7 Module 7).
  • 3.5's Helm 4.2.0 and GnuPG → Source Integrity, and 3.6's SSA → Server-Side Diff and OpenTelemetry environment variable renames can all change rendering, validation or monitoring behavior.
  • Upgrade the CLI and server together.

See Lesson 7 Module 7 Upgrades and disaster recovery,Lesson 2 Module 7 Resource tracking methods.

Where secrets are decrypted: this determines the risk and where to troubleshoot (#39–#42) Sealed SecretsGit: SealedSecret (ciphertext)Argo CD: syncs the ciphertext objectIn-cluster controller: private-key decryption → SecretError: SealedSecret eventRisk: loss of the private key (back it up!)#39 #40 External Secrets OperatorGit: ExternalSecret (reference)Argo CD: syncs the reference objectESO: pulls from Key Vault / VaultError: ExternalSecret statusRisk: identity and secret store availability#41 SOPS + CMPGit: SOPS-encrypted fileRepo Server plugin: decrypts and rendersPlaintext enters the rendered output and the Redis cacheError: ComparisonErrorRisk: the manifests can be read by anyone who can read them#42 #43
Figure 4-1 The later decryption happens (the closer to the workload), the fewer chances Argo CD has to touch plaintext
The wait chain from a Git push to “taking effect in the cluster” (#29 #43 #48 #49) Detect changeWebhook or polling120s + 60s jitter Queue for renderingparallelism.limitpending requests RenderEXEC_TIMEOUT 90sfailures are cached Comparestatus processors 20Cluster cache Syncoperation processors 10kubectl concurrency 20 Queueing at any stage shows up as “pushed but nothing changed”; first see which stage is waiting, then tune the corresponding parameter Default value sources: argocd-cm.yaml / argocd-cmd-params-cm.yaml / config-management-plugins.md (v3.6.1 docs)
Figure 4-2 Five places where things get “slow”

“Slow / not updating / abnormal after upgrade” troubleshooting decision tree

Starting from the symptom you see, locate the issue number step by step.

Environment Same as Module 0; Lab 4-A requires the Sealed Secrets controller (installed in Lesson 5 in kube-system) and kubeseal; Lab 4-B modifies the AppProject lab8. Output is an example.

Lab 4-A: ciphertext and namespace binding (#39)

kubectl create secret generic db-cred --from-literal=password=s3cr3t -n lab8-pb39 --dry-run=client -o yaml \
  | kubeseal --controller-namespace kube-system --format yaml > /tmp/db-cred.sealed.yaml
sed 's/namespace: lab8-pb39/namespace: lab8-pb39b/' /tmp/db-cred.sealed.yaml > /tmp/db-cred.moved.yaml
kubectl create ns lab8-pb39b; kubectl apply -f /tmp/db-cred.moved.yaml
sleep 3; kubectl -n lab8-pb39b get events --field-selector reason=ErrUnsealFailed -o custom-columns=MSG:.message
MSG
Failed to unseal: no key could decrypt secret (password)

Under strict scope, moving the ciphertext to another namespace makes it undecryptable — this is precisely its security design.

Cleanup:
kubectl delete ns lab8-pb39b

Lab 4-B: sync windows (#44)

argocd proj windows add lab8 --kind deny --schedule '* * * * *' --duration 1h --applications '*'
l8_app pb44 lab8/pb07 --sync-option CreateNamespace=true
argocd app sync lab8-pb44; echo "exit=$?"
FATA[0000] rpc error: code = PermissionDenied desc = cannot sync: blocked by sync window
exit=20
argocd proj windows list lab8
argocd proj windows enable-manual-sync lab8 0 && argocd app sync lab8-pb44      # allow manual sync within the window (break-glass)
argocd proj windows delete lab8 0

Lab 4-C: cached render errors (#43) and cleanup

mkdir -p ~/gitops-lab/lab8/pb43 && printf 'resources:\n- missing.yaml\n' > ~/gitops-lab/lab8/pb43/kustomization.yaml
cd ~/gitops-lab && git add lab8 && git commit -qm "lab8: pb43 broken" && git push -q
l8_app pb43 lab8/pb43 --sync-option CreateNamespace=true; for i in 1 2 3; do argocd app get lab8-pb43 --refresh >/dev/null; done; l8_why pb43 | tail -1

After several refreshes, the message may contain Manifest generation error (cached) (whether it appears, and the count threshold, depend on repo-server configuration; check actual output). After fixing the kustomization, use --hard-refresh to re-render immediately.

Cleanup:
l8_clean

Teaching videos (titles and channels verified via YouTube oEmbed)

▶
Why Argo CD Breaks at Scale (and How to Avoid It) — Octopus Deploy
English · scale (#48, #49)
▶
Mastering Efficiency in Argo CD: Scaling Smarter, Not Costlier - Alexander Matyushentsev, Akuity — CNCF [Cloud Native Computing Foundation]
English · controller and Repo Server efficiency
▶
Bitnami Sealed Secrets - How To Store Kubernetes Secrets In Git Repositories — DevOps & AI Toolkit
English · #39, #40
▶
Manage Kubernetes Secrets With External Secrets Operator (ESO) — DevOps & AI Toolkit
English · #41
▶
Argo Rollouts - Canary Deployments Made Easy In Kubernetes — DevOps & AI Toolkit
English · #45
▶
GitOps Without Pipelines With ArgoCD Image Updater — DevOps & AI Toolkit
English · #46 (the video may predate the v1.x ImageUpdater CR; follow the current docs for configuration)
▶
ArgoCD Notifications (Successful/Failed Deployments) — Anton Putra
English · #47

No verified video was found that specifically covers CMP troubleshooting, cached render errors, sync window break-glass, or 3.3 CRD upgrades; storyboard:

Shot 1 (0:00) Move a SealedSecret to another namespace → ErrUnsealFailed; explain strict scope and private key backup.
Shot 2 (1:00) A deny window blocks sync; enable-manual-sync demonstrate a controlled break-glass.
Shot 3 (2:00) Read the 3.2 → 3.3 upgrade notes, and use --server-side --force-conflicts to upgrade.

Official docs

or get ≥ 70% in the “Quiz”

Module 5 · Part B: GitOps and architecture (interview 1–13)

30:00 – 37:00 · tool-neutral GitOps: the four OpenGitOps principles, push vs pull, GitOps with CI applying directly, repo policies, secrets, drift and break-glass; Argo CD architecture and reconciliation; Argo CD vs Flux comparison and selection; self-management and v3 upgrades
7 minPrinciples → mechanisms → selection13 questions
Learning objectives
  • Be able to explain GitOps without naming any tool: the four principles, the security and operational benefits of pull-based reconciliation, and what it cannot solve (building, testing, database migrations, the secrets themselves).
  • Be able to draw Argo CD's components and one reconciliation's data flow on a whiteboard, and compare Flux's controller set to explain the design trade-offs between the two.
  • When answering selection questions, give decision criteria (team structure, multi-tenancy model, UI needs, Helm semantics, scale and topology) rather than “which is better.”

Browse the questions and focus areas first, mark the ones you're unsure of; click a row to jump to the details.

Q1. What is GitOps? What are the four OpenGitOps principles, and what problem does each solve?Beginner
30-second answer

GitOps is an operating model in which the system's desired state is stored declaratively in version control, and an agent running inside the environment automatically pulls it and continuously reconciles the actual state. OpenGitOps (the GitOps working group under CNCF) gives four principles: ①Declarative (Declarative); ②Versioned and immutable (Versioned and Immutable); ③Pulled automatically (Pulled Automatically); ④Continuously reconciled (Continuously Reconciled).

In-depth answer
  • Declarative: describe “what is wanted” rather than “how to do it,” which makes state comparable (diff) — this is the prerequisite for drift detection.
  • Versioned and immutable: every change has an author, a review, a timestamp and a revertible commit; auditing and rollback become Git operations. The principle says “versioned storage”; Git is just the most common implementation (OCI artifacts also satisfy it).
  • Pulled automatically: the agent pulls from the source rather than CI pushing — credentials stay inside the cluster, and external systems do not need cluster-admin permissions.
  • Continuously reconciled: not just applying on change, but continuously comparing and correcting drift; “deployment” changes from a one-time event into ongoing state maintenance.
Common follow-up questions
  • Storing YAML in Git and running kubectl apply in CI — does that count as GitOps? It only satisfies the first two principles; without pulling and continuous reconciliation, drift is invisible (Q3).
  • Does GitOps only apply to Kubernetes? The principles are general; Kubernetes's declarative API and controller pattern make it the most natural fit. Crossplane and similar tools let cloud resources be reconciled the same way.
Bonus points

Be able to say “Git is the single source of truth for desired state, but not for running state” — status, metrics and events still live in the cluster and monitoring systems; also mention the organizational changes the principles bring: changes go through PR review, and permissions shift from “who can access the cluster” to “who can merge into which directory.”

Common wrong answers

“GitOps is Argo CD” or “GitOps is putting the Jenkinsfile in Git” — confusing principles with tools, and CI with CD.

See Lesson 1 Module 1 GitOps principles.

Q2. What is the difference between push and pull deployment? Why does GitOps emphasize pull?Beginner
30-second answer

Push: the CI/CD system holds the cluster credentials and runs kubectl apply / helm upgrade. Pull: an agent inside (or next to) the cluster holds read-only credentials to the source, actively pulls the desired state and applies it. Pull keeps high-privilege credentials inside the cluster boundary, supports continuous reconciliation, is naturally suited to multi-cluster and network isolation (the cluster only needs outbound access to Git).

In-depth answer
DimensionPushPull
CredentialsCI holds cluster admin credentials (large blast radius)The agent holds read-only Git credentials; CI only needs to push to Git
NetworkCI must be able to reach every cluster's APIThe cluster reaches Git outbound; friendlier for private clusters
DriftApplied only once, when the pipeline runsContinuously compared, self-healing
ObservabilityPipeline logsReal-time Sync / Health status per application
Trade-offsSimple, immediate, with a clear “failure” signalEventually consistent; needs an extra mechanism to feed results back to CI (argocd app wait, notifications, commit status)
Common follow-up questions
  • Is Argo CD's hub-spoke model pull-based? Against Git it is pull; against spoke clusters the hub controller actually “pushes” to remote APIs — credentials are centralized in the hub. Pure pull requires one agent per cluster (Flux, an Argo CD per cluster, or agent mode); see Q29.
Bonus points

Mention that “push can also achieve auditing and review”; the value unique to pull is continuous reconciliation and the credential boundary; and pull shifts the control point for “who can deploy” to Git branch protection and CODEOWNERS.

Common wrong answers

“Pull is faster” — usually slower (polling), and needs webhook compensation (#29, #49).

Q3. The team currently uses a CI pipeline to directly kubectl apply / helm upgrade. How would you argue for migrating to GitOps? What are the migration risks?Intermediate
30-second answer

Arguments: ①drift is visible and correctable (manual hotfixes no longer quietly stay in production); ②credentials are consolidated (CI no longer holds production cluster admin); ③auditing and rollback unified into Git history; ④Multi-cluster consistency (the same declaration fans out to N clusters); ⑤Disaster recovery (new clusters rebuilt from Git). Risks: learning curve, feedback becomes asynchronous, Helm semantic changes, dual writes and resource takeover during migration.

In-depth answer
  • CI's responsibilities become: build → test → push image → update Git (image tag / values), then use argocd app wait or commit status to get the result.
  • Migration steps: first onboard in read-only mode (no auto-sync, observe the diff) → clean up differences (defaults, manual changes) → enable manual sync → enable auto-sync and selfHeal → finally revoke CI's cluster credentials.
  • Helm: Argo CD uses helm template to render and apply by itself, without creating a Helm release; resources that already have a release need to be taken over (Q48).
Common follow-up questions
  • How do you quantify the benefits? DORA metrics (deployment frequency, lead time for changes, change failure rate, time to restore) + drift event count + number of people holding production credentials.
  • What should not be put into GitOps? Short-lived batch jobs, objects dynamically generated by operators, and plaintext secrets.
Bonus points

Emphasize a gradual migration that “observes before acting,” plus a rollback plan; mention that separating CI and CD permissions helps compliance (SOC 2 change management controls).

Common wrong answers

“Just replace the pipeline's last step with argocd app sync” — that is still push-style thinking, and it conflicts with auto-sync (#20).

See Lesson 6 Module 1 From CI to GitOps.

Q4. How do you organize a GitOps repository? Single repo or multiple repos? Directories or branches for environments? Do application code and deployment configuration live together?Intermediate
30-second answer

Recommendation: keep the application code repo and the deployment config repo separate (avoids CI write-backs triggering themselves and keeps permissions separate); use directories (overlays/dev|staging|prod) for environments rather than long-lived branches. Whether to use a single or multiple repos depends on team boundaries — the platform layer gets one repo, and each team gets a config repo or is split by directory + CODEOWNERS within a single repo.

In-depth answer
  • Why not environment branches: promotion becomes a merge, branches accumulate differences that should not be promoted (environment-specific config), conflicts and cherry-picks are hard to audit; directories make “differences between prod and staging” obvious (diff -r).
  • Monorepo: good consistency and atomic cross-application changes; the costs are permission granularity, CI trigger scope, and Argo CD rendering storms (#49, using manifest-generate-paths to mitigate).
  • Multiple repos: clear permissions and a small blast radius; the costs are cross-repo changes and a version matrix.
  • “Rendered manifests” pattern: CI or Source Hydrator commits the Helm / Kustomize rendered output to environment branches / directories, so reviewers see the final YAML (Q11 discusses Argo CD's Source Hydrator, Beta).
apps/podinfo/base/            apps/podinfo/overlays/{dev,staging,prod}/
argocd/apps/  argocd/appsets/  argocd/projects/  argocd/root.yaml
bootstrap/argocd-values.yaml
Common follow-up questions
  • How is promotion done? A PR that copies the image tag / chart version from the staging directory to the prod directory (manual, or generated by a tool such as Kargo); see Q40.
Bonus points

Explain that “repo structure = org structure + permission model,” and mention branch protection, CODEOWNERS, and required checks (rendering, policy validation) as change control points for GitOps.

Common wrong answers

“One long-lived branch per environment; merging dev into main means going live” — this is the most common anti-pattern.

See Lesson 3 Module 1 Repo layout.

Q5. How do you manage secrets in GitOps? Compare the trade-offs of the main approaches.Intermediate
30-second answer

Principle: Never put plaintext in Git. Three approaches: ①encrypt and commit to Git (Sealed Secrets, SOPS) — Git is the single source, but key management and rotation are on you; ②reference in Git, values in an external secret store (External Secrets Operator, Secrets Store CSI Driver) — the secret store is the source, and Git only holds “where to fetch from”; ③inject at deploy time (CMP / plugin rendering) — the most flexible and also the most dangerous; plaintext passes through the GitOps tool.

In-depth answer
ApproachWhere decryptedAdvantagesRisks
Sealed SecretsIn-cluster controllerSimple, works offlineper-cluster private keys, backup and rotation; re-encryption
SOPS (+ KMS / age)Rendering tool / pluginReadable file structure, KMS auditingPlaintext enters rendering and cache (#42)
ESOIn-cluster operatorCentralized rotation, auditing, integration with cloud identityDepends on secret store availability and identity configuration (#41)
CSI DriverNode mountMay avoid creating a Secret objectThe application must read files; differs from the env variable approach
Common follow-up questions
  • What if plaintext was already committed? Revoke and rotate first, then clean up the history (Q43).
  • How do you make rotation take effect automatically? ESO refresh + Reloader / rolling-restart annotation; or the application hot-reloads directly from mounted files.
Bonus points

Point out that a Kubernetes Secret is merely base64 and needs etcd encryption (KMS provider) and RBAC; and that the source of secrets should match the organization's existing secret store (Key Vault, Vault, Secrets Manager).

Common wrong answers

“Base64-encode it and put it in Git” or “a private repo is safe.”

See Lesson 5 Module 3 Secrets management selection.

Q6. How does GitOps handle drift? When you need to bypass Git in an emergency (break-glass), what should the process look like?Advanced
30-second answer

Drift = actual state deviates from Git. The agent detects it continuously; policies come in three levels: alert only (OutOfSync + notification),auto-correct (selfHeal),deliberately ignore (ignoreDifferences, for fields owned by other controllers). Break-glass process: approval, time limit, and a record, and afterwards backfill the change into Git or revert it, so that Git becomes the source of truth again.

In-depth answer
  • Break-glass options (lightest to heaviest): ① an emergency PR through fast review (preferred; GitOps itself is the fastest path); ② temporarily pause self-healing: turn off the application's selfHeal selfHeal / auto-sync (change in Git or via an authorized API), fix manually, backfill later; ③ in a sync window, the manualSync override (#44); ④ full bypass (direct kubectl) only when Argo CD itself is unavailable.
  • Record who, when, why and what changed; within 24 hours afterwards, backfill Git and restore automation — “a temporarily disabled selfHeal” is the configuration most often forgotten.
  • Tool-neutral: Flux likewise has suspend (flux suspend kustomization …) and resume; the principle is the same.
Common follow-up questions
  • Should selfHeal be on everywhere? For production, it is recommended to enable it, combined with RBAC restricting manual changes and ignoreDifferences excluding legitimate external changes; otherwise it fights with HPA / operators (#13).
  • How do you find the source of drift? The manager names in managedFields, and audit logs.
Bonus points

Treat break-glass as a rehearsed process (quarterly drills), and track “OutOfSync duration” and “selfHeal count” as platform health indicators.

Common wrong answers

“Under GitOps you must never change anything by hand” — in reality break-glass is needed; the key is that it is controlled and can be backfilled.

Q7. Draw Argo CD's architecture: what components are there, and what does each one do?Intermediate
30-second answer

argocd-server (API, UI, authentication and RBAC decisions, webhook entry); argocd-repo-server (clones repos, resolves revisions, renders manifests: Kustomize / Helm / plain YAML / CMP; stateless and horizontally scalable); argocd-application-controller (StatefulSet: maintains the cluster cache, compares desired and live state, performs syncs, evaluates health, writes Application status back; can be sharded by cluster); Redis (caches rendered results and the application tree; not the persistent source of truth); argocd-applicationset-controller (generates Applications); Dex (optional, SSO connector); argocd-notifications-controller (notifications). All configuration and state are stored in Kubernetes objects (CRDs, ConfigMaps, Secrets).

In-depth answer
  • No database: Application / AppProject / ApplicationSet are CRDs; settings are in argocd-cm,argocd-rbac-cm,argocd-cmd-params-cm; credentials and clusters live in labeled Secrets — this is what makes “Argo CD managed by GitOps” possible (Q13).
  • Losing Redis only affects performance (re-rendering and rebuilding caches); it does not lose the source of truth.
  • Source Hydrator (Beta) also uses commit-server to commit rendered results back to Git.
Common follow-up questions
  • Which component needs to access target clusters? controller (and server for the resource tree / logs / actions); repo-server only accesses Git / Helm / OCI.
  • Which component should you scale to solve which problem? Slow rendering → repo-server; many applications / many clusters → controller sharding; UI/API traffic → server.
Bonus points

Mention the security implications: repo-server executes user-provided templates and plugins, so it is the focus of isolation (network policies, no SA token mounted); the controller holds high privileges on target clusters.

Common wrong answers

“Argo CD stores application definitions in Redis / a database.”

See Lesson 1 Module 2 Architecture.

Q8. Describe one reconciliation loop. What is the difference between refresh and hard refresh? How often does reconciliation happen by default?Intermediate
30-second answer

The controller periodically (timeout.reconciliation default 120 seconds, plus up to 60 seconds of jitter) or on a webhook / user request processes applications: asks repo-server for the manifests at the target revision (returned directly if cached) → compares with live objects in the cluster cache → derives Sync Status and Health → starts a sync if auto-sync is enabled → writes back status. refresh A refresh only re-compares (re-renders only when the revision changes); hard refresh a hard refresh also discards the manifest cache and forces re-rendering.

In-depth answer
  • Live state comes from the controller's watch cache (not a list on every reconcile), so in-cluster changes are visible almost in real time; Git changes depend on polling or webhooks.
  • The render cache key includes the revision SHA and the application's source parameters; it expires after 24 hours by default (reposerver.default.cache.expiration).
  • Render failures are cached (#43); hard refresh is the way to bypass the cache.
argocd app get podinfo-dev --refresh
argocd app get podinfo-dev --hard-refresh
Common follow-up questions
  • Why add jitter? To avoid spikes caused by thousands of applications reconciling at the same time.
  • Which changes in v3 reduce wasteful reconciliation? Status fields are ignored by default, ignoreDifferences is used to ignore resource updates, and default resource.exclusions are applied.
Bonus points

Be able to break “how long until a push takes effect” into five stages: detect, queue, render, compare, sync (Figure 4-2).

Common wrong answers

“Run git pull every 3 minutes and then kubectl apply everything.”

Q9. What is the difference between Sync Status, Health Status and Operation State? Give examples of “Synced but Degraded” and “OutOfSync but Healthy.”Beginner
30-second answer

Sync Status: whether desired and live state match (Synced / OutOfSync / Unknown). Health: whether the resources themselves are healthy (Healthy / Progressing / Degraded / Suspended / Missing / Unknown). Operation State: the result of the most recent sync operation (Running / Succeeded / Failed / Error / Terminating). The three are independent.

In-depth answer
  • Synced + Degraded: Git specifies a non-existent image tag; the objects match, but Pods cannot pull the image (#22).
  • OutOfSync + Healthy: HPA changed the replica count (#13), or there are resources waiting to be pruned (#23).
  • Unknown: the comparison did not complete (rendering failure, cluster unreachable).
  • Missing: a desired resource does not exist in the cluster (not yet synced).
Common follow-up questions
  • Which status should CI wait for? argocd app wait --sync --health— and check the operation state, to avoid mistaking an old healthy version for success (compare the synced revision).
Bonus points

Mention that in App of Apps, the health of child Applications is not evaluated by default (removed since 1.8); a custom health check is needed for waves to wait for child application health.

Common wrong answers

“Synced means the deployment succeeded.”

See Lesson 1 Module 5 State model.

Q10. What is the fundamental architectural difference between Argo CD and Flux?Intermediate
30-second answer

Argo CD is an Application-centric platform: a centralized controller plus its own API Server, UI, SSO, RBAC and multi-cluster management (hub-spoke). Flux (v2; the latest as of the verification date is v2.10.0) is a set of composable Kubernetes controllers (GitOps Toolkit): source-controller (fetches from Git / Helm / OCI / Bucket), kustomize-controller, helm-controller, notification-controller, image-reflector / image-automation-controller, declared via CRDs (GitRepository, Kustomization, HelmRelease…); usually each cluster runs its own set.

In-depth answer
DimensionArgo CDFlux
Interaction entry pointWeb UI + CLI + API, with its own user systemCLI + kubectl; no built-in web UI (third-party / operator-provided interfaces exist in the ecosystem; check actual options)
Permission modelOwn RBAC (Casbin) + AppProject + SSOKubernetes RBAC; controllers impersonate a specified ServiceAccount (impersonation)
Helmhelm template Renders and applies by itself, no Helm releasehelm-controller uses the Helm SDK to perform real install / upgrade, with release history and Helm hook semantics
Multi-clusterOne instance manages multiple clusters (credentials centralized)Usually one set per cluster (pure pull); remote kubeconfig is also possible
Unit of extensionApplication / ApplicationSetKustomization / HelmRelease and dependencies (dependsOn)
Common follow-up questions
  • Are both CNCF graduated projects? Yes (both Argo and Flux have graduated); maturity is not the differentiator.
Bonus points

Reduce the difference to “platform product vs toolkit”: Argo CD is an out-of-the-box multi-tenant portal; Flux is closer to Kubernetes-native and easier to embed in a custom-built platform.

Common wrong answers

“Flux does not support Helm” or “Argo CD does not support Kustomize.”

Q11. What concrete production impacts do the differences between Argo CD and Flux in multi-tenancy and Helm handling have?Advanced
30-second answer

Multi-tenancy: Argo CD's boundary is AppProject + Argo CD RBAC, the controller itself usually has very high cluster privileges, and isolation relies on Argo CD's validation; Flux's boundary is Kubernetes RBAC, tenants' Kustomization / HelmRelease run under the tenant's own ServiceAccount, and permissions are enforced by the API Server. Helm: Argo CD does not produce a release,lookup (the Helm CLI is not available), Helm hooks are mapped to Argo CD hooks; Flux keeps the full Helm lifecycle (release history, rollback, hooks,helm list visibility).

In-depth answer
  • Argo CD can also narrow permissions: project-level destinations and allowlists, and v3.x impersonation (the 3.4 → 3.5 upgrade notes mention “Impersonation extended to server operations”) lets syncs run as a specified ServiceAccount.
  • Helm impact: charts that depend on lookup (random password generation) change on every render in Argo CD (OutOfSync loop); helm.sh/hook are executed in Argo CD via their mapping (e.g., pre-delete → PreDelete); operational habits (helm rollback) no longer apply; rollback is git revert.
  • Flux's Helm driver also has costs: release Secret size, and configuration for remediating failed releases.
Common follow-up questions
  • Which is smoother to migrate to from the Helm CLI? Flux (keeps the release); migrating to Argo CD requires taking over resources and cleaning up the release Secret (Q48).
Bonus points

Point out that “who enforces isolation” is the core question of a security review: enforcement by the API Server (Flux impersonation / Argo CD impersonation) is more reliable than application-layer validation.

Common wrong answers

“Argo CD's AppProject and Kubernetes RBAC are the same thing.”

Q12. Your company needs to choose a GitOps tool (20 teams, 8 clusters, developers want a UI). How would you choose? Can the two coexist?Advanced
30-second answer

Decide by criteria rather than preference: strong demand for developer self-service and visualization, and a need for a centralized multi-cluster view with SSO/RBAC → lean toward Argo CD; platform teams wanting Kubernetes-native, per-cluster autonomy, strong Helm semantics, and embedding into a home-built platform → lean toward Flux. For this scenario (UI, 20 teams, centralized governance) I would choose Argo CD and use AppProject + SSO groups + ApplicationSet to build a self-service model. Coexistence is feasible: for example, Flux handles cluster bootstrap and the platform layer while Argo CD handles the application layer — but draw a clear line on “who manages which object,” so the two reconcilers do not fight over the same resource.

In-depth answer
  • Evaluation matrix: UI / self-service, multi-tenancy model, scale and topology (hub-spoke vs per cluster), Helm semantics, ecosystem (Rollouts / Flagger, Image Updater / image-automation, Kargo supports both), team skills, managed services (AKS's GitOps extension is based on Flux; commercially managed Argo CD offerings also exist).
  • Run a 2-week PoC with 3 real applications and 2 clusters to validate permissions, upgrades, failure recovery and developer experience.
  • Coexistence boundaries: split by namespace or resource type; set ignore or exclusion for objects managed by the other tool, to prevent SharedResource-style conflicts (the cross-tool version of #24).
Common follow-up questions
  • How do you choose for progressive delivery? Argo CD is often paired with Argo Rollouts; Flux is often paired with Flagger — both can be combined with either GitOps tool.
Bonus points

Mention “exit cost”: both sources are standard Kubernetes manifests in Git; migration cost lies mainly in the CRD wrapper layer (Application vs Kustomization / HelmRelease) and operational processes, not in the applications themselves.

Common wrong answers

“Argo CD is more popular, so pick it” — there is no such standard; or “coexistence has no problems” — ignoring ownership conflicts.

Q13. How does Argo CD manage itself (self-management / bootstrap)? When upgrading from v2 to v3, what would you focus on checking?Advanced
30-second answer

Bootstrap: install once manually with Helm (or kustomize) → create an bootstrap/ Application that manages Argo CD itself (chart + values) → a root app (App of Apps) manages projects, repos, clusters and all applications. Afterwards, upgrading means changing the chart version in Git. Key points for the v3 upgrade: the tracking method changes by default to annotations,log RBAC enforced,update/delete no longer inherited,old repository configuration in argocd-cm removed, default resource.exclusions, ignoring status, some metrics removed; and for 3.3 CRDs must be applied server-side, for 3.5 Helm 4 and Source Integrity, and for 3.6 SSA → Server-Side Diff.

In-depth answer
  • Risk of self-management: one bad values commit can take Argo CD itself down, losing its self-healing ability — you need to keep a manual helm upgrade recovery path and break-glass documentation.
  • Self-managed applications should enable ServerSideApply=true (from 3.3 onward it is a prerequisite for upgrades, #50), disable prune or use Prune=false to protect CRDs and Secrets.
  • Upgrade process: one minor version at a time, read the Detection section of each upgrade note, upgrade the staging instance first,argocd admin export back up, watch metrics (reconcile duration, memory).
Common follow-up questions
  • Which metrics were removed in v3? argocd_app_sync_status,argocd_app_health_status,argocd_app_created_time (replaced by the labels of argocd_app_info ), and alerting rules must be updated accordingly.
Bonus points

Be able to say that after upgrading you “sync all applications once” to write the tracking annotations, avoiding orphan resources (the warning in the 2.14 → 3.0 upgrade notes).

Common wrong answers

“Just kubectl apply the latest install.yaml” — from 3.3 onward this fails because of over-long CRD annotations.

See Lesson 3 Module 2,Lesson 7 Module 7.

Interview whiteboard diagram: the same GitOps principles, two implementations (Q7, Q10, Q11) Argo CD (platform) server · UI · RBAC repo-server rendering Redis cache application-controller: compare · sync · health (sharded by cluster) cluster lab cluster lab2 cluster … Flux (toolkit, one set per cluster) source-controller notification-controller kustomize-controller helm-controller (real release) impersonates the tenant ServiceAccount → enforced by Kubernetes RBACimage-reflector / image-automation writes back to Git
Figure 5-1 Common ground: declarative, versioned, pull, continuous reconciliation; differences: entry point, permission enforcement point, Helm semantics, topology

Scenario 5-1: persuade a team that “runs helm upgrade directly from CI” to migrate to GitOps

The team has 12 microservices; the Jenkins pipeline holds the production cluster's kubeconfig, and every helm upgrade --install. Last quarter there were two incidents: once, an on-call engineer manually edited a ConfigMap and it was overwritten by the next deployment; once, an audit failed on the risk of Jenkins credential leakage. Please provide a migration plan and timeline.

Key points of the reference answer
  • Use their own incidents to explain the benefits: drift is visible (manual changes show as OutOfSync), production credentials are taken back from Jenkins, and the audit record lives in Git.
  • Phases: ① set up the config repo and directory structure (Q4), and change Jenkins to open PRs that update image tags; ② onboard Argo CD with manual sync, only observe the diff, and clean up default-value differences; ③ take over Helm release resources (Q48) and delete the release Secret; ④ enable auto-sync + selfHeal, and CI uses argocd app wait to get the result; ⑤ revoke Jenkins's cluster credentials.
  • Risk control: every phase is reversible; migrate non-critical services first; rehearse the break-glass process (Q6) in advance.

Scenario 5-2: write a one-page decision record (ADR) for choosing Argo CD or Flux for a platform

The platform team has 4 people, supporting 30 development teams, with 2 clusters in each of 3 regions; the security team requires “tenants may only affect their own namespaces, enforced by the API Server”; developers want to self-serve deployment status and logs.

Key points of the reference answer
  • List criteria and weights: self-service UI, permission enforcement point, topology, Helm semantics, operational cost, ecosystem.
  • Candidate options: A. Argo CD hub (UI, SSO, AppProject) + syncs using impersonation to satisfy “enforced by the API Server”; B. Flux per cluster + third-party UI; C. Flux bootstrapping the platform layer + Argo CD for the application layer.
  • Example conclusion: choose A, with reasons and risks (centralized hub credentials → one instance per region, network isolation, auditing), and state the triggers for re-evaluation (cluster count > 50, need for offline clusters).
or get ≥ 70% in the “Quiz”

Module 6 · Part B: Application and sync (interview 14–25)

37:00 – 44:00 · Application spec, auto-sync / prune / selfHeal, waves and hooks, sync options, diff strategies, ignoreDifferences, custom health, multi-source, rollback, resource tracking, Helm semantics, deletion and cascading
7 minSpec → sync → diff → lifecycle12 questions
Learning objectives
  • Be able to explain a production-grade Application field by field, and state the applicable scenarios and risks of each sync option.
  • Be able to explain the three diff strategies and the v3.6 changes, and the difference between “ignore differences” and “also ignore during sync.”
  • Be able to answer common follow-ups such as “how to roll back under GitOps” and “what happens when an application is deleted,” citing real issues from Part A.

Browse the questions and focus areas first; click a row to jump to the details.

Q14. Explain a production-grade Application manifest section by section.Beginner
30-second answer

metadata (name, namespace argocd,resources-finalizer) → spec.project (permission boundary) → source/sources (repoURL, targetRevision, path or chart, Kustomize/Helm parameters) → destination (server or name + namespace) → syncPolicy (automated, syncOptions, retry, managedNamespaceMetadata) → ignoreDifferences.

apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
  name: podinfo-prod
  namespace: argocd
  finalizers: [resources-finalizer.argocd.argoproj.io]     # cascade on deletion
  annotations:
    notifications.argoproj.io/subscribe.on-health-degraded.slack: podinfo-alerts
spec:
  project: team-a
  source:
    repoURL: https://github.com/<you>/gitops-lab
    targetRevision: main
    path: apps/podinfo/overlays/prod
  destination: {name: lab, namespace: podinfo-prod}
  syncPolicy:
    automated: {prune: true, selfHeal: true}
    syncOptions: [ServerSideApply=true, PruneLast=true, FailOnSharedResource=true]
    retry: {limit: 3, backoff: {duration: 10s, factor: 2, maxDuration: 3m}}
Common follow-up questions
  • Why is it acceptable to use a branch for prod's targetRevision? If the branch is protected and promotion goes through PRs, the branch is the “latest approved state”; stricter teams use tags.
  • What are the risks of the finalizer? Deletion cascades to delete workloads; for stuck deletion see #25.
Bonus points

Point out that this manifest itself is also in Git (argocd/apps/) and is managed by the root app, avoiding imperative changes (#12).

Common wrong answers

Filling in both destination server and name, or thinking a project is merely a “grouping label.”

Q15. What are automated, prune, selfHeal and allowEmpty? How would you configure them in production?Intermediate
30-second answer

automated: automatically syncs when a new revision appears in Git. prune: automatically deletes resources that no longer exist in Git. selfHeal: also automatically syncs back to the desired state when the live state is changed (with no new commit). allowEmpty: allows the application to have no resources after pruning (disallowed by default, to prevent deleting everything when rendering comes back empty). Production: auto-sync + selfHeal + prune, but add Prune=false / Delete=false, and keep allowEmpty: false.

In-depth answer
  • Auto-sync only applies to new revisions— it triggers once per revision; after a sync failure it does not retry the same revision indefinitely (unless retry is configured).
  • selfHeal has a timeout / backoff (controller.self.heal.timeout.seconds, deprecated since 3.3: --self-heal-backoff-cooldown-seconds).
  • allowEmpty: false is the last line of defense against “rendering an empty list” (a wrong path, a generator returning nothing, or values disabling all resources).
Common follow-up questions
  • Should prod use auto-sync? It depends on whether promotion already has gates (PR review, tests, sync windows); with gates, auto-sync is safer (it reduces the arbitrariness of manual syncs).
Bonus points

Connect to #23 and #42 (post-mortem): the biggest risk of prune is “accidentally deleting stateful resources”; protect them with resource-level annotations instead of turning prune off globally.

Common wrong answers

“selfHeal is just retrying failures.”

See Lesson 1 Module 7.

Q16. What is the execution order of Sync Waves and resource hooks? Give an example of a database migration + application release.Intermediate
30-second answer

By phase: PreSync → Sync → PostSync (on any failure, runs SyncFail); deleting an application also has PreDelete / PostDelete. Within each phase, sort by argocd.argoproj.io/sync-wave from smallest to largest; within the same wave, sort by kind (Namespace, CRD, etc. first) and name; after each wave is applied,wait for health before moving to the next wave.

db-migrate Job:   hook: PreSync, hook-delete-policy: BeforeHookCreation, activeDeadlineSeconds: 600
ConfigMap:        sync-wave: "-1"
Deployment:       sync-wave: "0"
smoke-test Job:   hook: PostSync
notify-fail Job:  hook: SyncFail
In-depth answer
  • Hook deletion policies: HookSucceeded,HookFailed,BeforeHookCreation (most commonly used; avoids a same-name Job already existing).
  • There is a brief artificial delay between waves to give other controllers time to react (the source comment cites issue #4669).
  • A stuck hook blocks the entire sync (#19), so hooks must have a timeout.
Common follow-up questions
  • What about Helm's pre-install hooks? They are mapped to Argo CD hooks (for example pre-install / pre-upgrade → PreSync; pre-delete → PreDelete).
  • Can waves order child applications in App of Apps? Yes, but you need to configure a health check for the Application; otherwise it will not wait for the child application's health.
Bonus points

Migration scripts must be backward compatible (expand / contract), because after PreSync succeeds the Deployment may fail and roll back (Q49).

Common wrong answers

“Higher waves run first” or “all resources are applied at once and waves are just labels.”

See Lesson 2 Module 4.

Q17. What are the common sync options? In what scenarios is each of ServerSideApply, Replace, CreateNamespace, PruneLast and ApplyOutOfSyncOnly used?Intermediate
30-second answer
  • ServerSideApply=true: large objects (avoids the last-applied annotation exceeding its limit, #15), and coexisting with other field managers; from 3.6 Server-Side Diff is also enabled.
  • Replace=true: immutable fields that truly need replace / create semantics; there is a risk of delete-and-recreate, so use with caution.
  • CreateNamespace=true: creates the target namespace (#17), together with managedNamespaceMetadata.
  • PruneLast=true: prune after all waves complete, to reduce disruption.
  • ApplyOutOfSyncOnly=true: applies only the resources that have differences, reducing API pressure for large applications (switching tracking methods in v3 needs special handling, #50).
  • There are also Validate=false,SkipDryRunOnMissingResource=true,RespectIgnoreDifferences=true,FailOnSharedResource=true,Prune=false|confirm,Delete=false|confirm,PrunePropagationPolicy.
Common follow-up questions
  • Can options be added to individual resources? Yes, using the annotation argocd.argoproj.io/sync-options (separate multiple values with commas).
  • What is a Force sync? It deletes and recreates conflicting resources (together with Replace), which causes an outage.
Bonus points

Give a default template: ServerSideApply=true, PruneLast=true, FailOnSharedResource=true, and add to stateful resources Prune=false.

Common wrong answers

Treating Replace as a switch that “solves all apply errors.”

See Lesson 2 Module 3.

Q18. How does Argo CD compute diffs? What is the difference between Legacy diff and Server-Side Diff? What changed in v3.6?Advanced
30-second answer

Legacy: inside the controller, a three-way merge (last-applied, desired, live) plus normalization approximates the API Server's result; it cannot see server-side defaults or webhook modifications, so it easily produces false diffs (#14). Server-Side Diff: performs an SSA dry-run against the API Server to get “what would be applied now” and compares that with the live object — accurate, but adds API requests. v3.6: Structured-Merge Diff was removed; enabling ServerSideApply=true applications automatically use Server-Side Diff; validating webhooks reject resources already during the diff stage.

In-depth answer
  • How to enable: controller.diff.server.side: "true" (globally), the annotation argocd.argoproj.io/compare-options: ServerSideDiff=true (per application); ServerSideDiff=false the annotation always takes precedence, and you can fall back to Legacy.
  • Results are cached, and requests are only sent on refresh, a new revision, a spec change, or a change in the resource's resourceVersion.
  • CLI: argocd app diff --server-side-diff.
Common follow-up questions
  • Does Server-Side Diff modify the cluster? No, it is a dry-run.
  • Impact on API Server load? Proportional to the number of resources using SSA; at large scale, watch the apiserver request rate.
Bonus points

Be able to say that diff and sync are two different things: Server-Side Diff decides “whether it is OutOfSync,” and SSA decides “how it is written.”

Common wrong answers

“Argo CD directly compares YAML text.”

See Lesson 2 Module 6.

Q19. How do you design ignoreDifferences? What are the differences between jsonPointers, jqPathExpressions and managedFieldsManagers? When is RespectIgnoreDifferences still needed?Intermediate
30-second answer

jsonPointers: exact path (/spec/replicas); jqPathExpressions: can select by condition (for example, a particular field of a container with a given name); managedFieldsManagers: ignores fields written by specified field managers (such as kube-controller-manager, a particular operator). ignoreDifferences only affects comparison; during sync, the value from Git is still written back unless RespectIgnoreDifferences=true is added.

ignoreDifferences:
- group: apps
  kind: Deployment
  jqPathExpressions:
  - '.spec.template.spec.containers[] | select(.name == "istio-proxy")'
- group: admissionregistration.k8s.io
  kind: MutatingWebhookConfiguration
  jsonPointers: [/webhooks/0/clientConfig/caBundle]
Common follow-up questions
  • Global or per application? Put what all applications share in argocd-cm the resource.customizations.ignoreDifferences.<group_kind>; put application-specific settings in the Application.
  • What are the default changes in v3? The system-level ignoreDifferences is also used by default to ignore resource update events; status is ignored by default.
Bonus points

Emphasize that “the best ignoreDifferences is the one you don't need”: first remove from Git the fields you should not be managing.

Common wrong answers

Using ignoreDifferences to hide real drift (for example, a manually changed image).

Q20. How does Argo CD determine health? How do you write a custom health check for a CRD?Intermediate
30-second answer

Built-in checks (gitops-engine) cover Deployment, StatefulSet, DaemonSet, ReplicaSet, Pod, Job, PVC, Service, Ingress, HPA, APIService and more; there are also many community Lua checks (cert-manager, Rollouts, ESO, etc.). For custom checks, write a Lua script in argocd-cm the resource.customizations.health.<group_kind> configuration that returns {status, message}.

resource.customizations.health.example.com_Widget: |
  hs = {status = "Progressing", message = "Waiting"}
  if obj.status ~= nil and obj.status.conditions ~= nil then
    for _, c in ipairs(obj.status.conditions) do
      if c.type == "Ready" and c.status == "True" then hs.status = "Healthy"; hs.message = c.message end
      if c.type == "Ready" and c.status == "False" then hs.status = "Degraded"; hs.message = c.message end
    end
  end
  return hs
Common follow-up questions
  • Health of child applications in App of Apps? Since 1.8, health is not evaluated by default for argoproj.io/Application 's health; a custom check is needed for waves to wait (official health docs).
  • Why does an Ingress stay Progressing? No load balancer address (#21).
Bonus points

Health checks are the “brakes” of automation: they decide whether waves advance, whether RollingSync continues, and whether notifications are sent.

Common wrong answers

“Healthy just means Pods are Running.”

See Lesson 2 Module 5.

Q21. What problems do multi-source Applications solve? What are the pitfalls?Intermediate
30-second answer

Typical use: the chart comes from an external Helm repository, and the environment values come from your own Git repo (ref: values + $values/…); or one application is composed of multiple directories. Pitfalls: the two sources' versions get out of sync, the project must allow all sources,valueFiles path syntax (#9), and revision history and rollback in the UI are more complex.

In-depth answer
  • Each source resolves its revision independently; a new commit in any one source triggers a sync.
  • argocd app manifests --revisions … --source-positions … You can view the rendered result for a specified combination of source revisions.
  • Alternatives: use an “umbrella chart” (depending on the external chart + your own values) or Kustomize's helmCharts feature, keeping a single source.
Common follow-up questions
  • How do you roll back with multiple sources? Roll back Git (both sources must return to a consistent combination); argocd app rollback there are limitations for multi-source; follow the docs.
Bonus points

Give selection criteria: external chart + a few values → multi-source; need to patch or combine multiple charts → umbrella chart or Kustomize.

Common wrong answers

Thinking that valueFiles can take any URL.

See Lesson 2 Module 2.

Q22. How do you roll back under GitOps? argocd app rollback and git revert — what is the difference?Beginner
30-second answer

Preferred: git revert: the desired state returns to the previous version, with auditing and reviewability; auto-sync will apply it. argocd app rollback Sync the application to a revision from history, but Git still points at the new version —auto-sync must be turned off first, otherwise the next reconciliation syncs back to the new version; it is suitable for emergencies, and Git must be backfilled afterwards.

In-depth answer
  • A Rollouts “abort” only returns to the stable replicas while Git still holds the new version (#45); a revert is needed here too.
  • When database migrations are irreversible, rolling back the application version may not be enough — you need a forward fix or backward-compatible migrations (Q49).
  • Rollback drills: periodically verify the time from “Git revert” to “cluster recovered,” as a component of MTTR.
Common follow-up questions
  • Need to roll back multiple applications together? Revert one promotion PR at a time (Q40), so the promotion granularity determines the rollback granularity.
Bonus points

Point out that History and Rollback in the UI depends on the application's revision history (revisionHistoryLimit).

Common wrong answers

“Just kubectl rollout undo” — selfHeal will revert it.

Q23. How does Argo CD know which application a resource belongs to? What is the difference between label and annotation tracking?Intermediate
30-second answer

Through tracking information: v3 defaults to annotation argocd.argoproj.io/tracking-id: <app>:<group>/<kind>:<namespace>/<name>; the old label method uses app.kubernetes.io/instance (configurable application.instanceLabelKey); there is also annotation+label. The annotation method is more reliable: labels get copied by other tools onto derived resources (for example, an operator copies labels to objects it creates), causing misjudgment and accidental deletion; label values are also limited to 63 characters.

In-depth answer
  • Configuration: argocd-cm in application.resourceTrackingMethod; you can opt out (label), and the official docs say there are no plans to remove label tracking.
  • Edge case when switching: if the first sync after switching includes deletions, orphans may result (#50); it is recommended to sync all applications once after switching.
  • SharedResourceWarning is detected using tracking information (#24).
Common follow-up questions
  • Multiple Argo CD instances managing the same cluster? You must use different tracking keys / installationIDs to avoid claiming each other's resources.
Bonus points

Be able to write out the tracking-id format and use it to troubleshoot “who keeps changing it back” (#12).

Common wrong answers

“Argo CD tracks resources through ownerReference.”

See Lesson 2 Module 7.

Q24. What behavioral differences exist between Argo CD deploying a Helm chart and helm install ? Which chart patterns cause problems?Advanced
30-second answer

Argo CD uses helm template to render, then applies by itself: no Helm release (helm list is empty), no helm rollback; Helm hooks are mapped to Argo CD hooks; lookup functions have no cluster access during rendering and return empty; random functions (randAlphaNum) differ on every render, causing permanent OutOfSync; .Release.Name the default release name is the application name (can be overridden with releaseName ); Capabilities.APIVersions depends on the API version information that Argo CD passes in.

In-depth answer
  • Random passwords / certificates: switch to providing them from external secrets (ESO) or cert-manager, or reference an existing Secret in the chart.
  • v3.5 upgrades the built-in Helm to 4.2.0 (upgrade notes); OCI and TLS behavior changed (for example, HTTP OCI repositories need explicit marking).
  • Kustomize is also built in (upgraded to 5.8.0 in 3.3); when a specific version is needed, you can, in argocd-cm configure multiple Kustomize versions.
Common follow-up questions
  • What if you want a real Helm release? Use Flux's helm-controller (Q11), or accept Argo CD's model.
Bonus points

When reviewing a chart, list “GitOps compatibility checks”: no lookup, no random values, hooks have deletion policies, and resource names do not depend on the release revision number.

Common wrong answers

“Argo CD internally runs helm upgrade.”

See Lesson 2 Module 1,Helm 8 hours.

Q25. What happens when you delete an Application? What is the difference between cascading, non-cascading, foreground and background?Intermediate
30-second answer

With resources-finalizer.argocd.argoproj.io , deleting the application will cascade-delete all resources it manages (default foreground propagation policy: wait until child resources are deleted); without the finalizer, or when using --cascade=false , only the Application object is deleted, and the resources are kept as orphans. -p background lets Kubernetes reclaim child objects in the background.

In-depth answer
  • For common causes of stuck deletion and how to handle them, see #25; PreDelete / PostDelete hooks run during the whole application deletion.
  • Delete=false Resources with the annotation are kept when the application is deleted (for example PVCs, namespaces); CreateNamespace=true namespaces that get created are not deleted.
  • The cascade when an ApplicationSet is deleted is controlled by preserveResourcesOnDeletion (#28).
Common follow-up questions
  • How do you “move” resources from one application to another without downtime? First non-cascading delete the old application (or remove the resources from the old application and Prune=false), then the new application takes over (the tracking annotations get rewritten).
Bonus points

Point out that deletion is also a change and needs review and approval (in App of Apps, deleting an Application file = deleting workloads).

Common wrong answers

“Deleting an application does not affect cluster resources” — by default it does.

See Lesson 7 Module 6.

The order of one sync (Q16) and where common options apply (Q17) dry-runSkipDryRunOn…Validate=false PreSync hookMigration Jobmust have a timeout Sync: wave -1 → 0 → 1Wait for health per wave · SSA / ReplaceCreateNamespace · ApplyOutOfSyncOnly PostSync hookSmoke testNotification PrunePruneLastPrune=false/confirm Any stage failure → SyncFail hook; auto-sync retries with backoff per retry; new syncs are rejected during an operation (#20)Deleting an application: PreDelete → cascading deletion (finalizer) → PostDelete (Q25)
Figure 6-1 Draw and explain while interviewing: each box corresponds to a real issue

Scenario 6-1: how do you safely release a service with a database migration in Argo CD?

The order service's each release may include a database schema change; requirements: if the migration fails, the new code must not go live; if the new code fails, it must be rollback-able; no data loss allowed.

Key points of the reference answer
  • The PreSync Job runs the migration (BeforeHookCreation, timeout, idempotent); on failure the sync fails and the Deployment is not updated.
  • The migration follows expand/contract: first add columns / tables (old and new code can both run), then delete old columns in the next version.
  • The Deployment uses Rollouts canary + analysis; on failure Rollouts returns to the stable version, and Git is reverted.
  • PostSync smoke tests; SyncFail hook notifications; the database backup completes before the migration (the first step of the migration Job, or a separate backup CronJob).

Scenario 6-2: an application has been OutOfSync for a long time, and the team proposes “globally disable selfHeal and prune”

15% of the applications on the platform have been OutOfSync for a long time, for various reasons: HPA, Istio injection, operators changing fields, someone manually editing a ConfigMap. Please propose a solution that does not sacrifice GitOps guarantees.

Key points of the reference answer
  • Classify: fields owned by external controllers (remove from Git, or ignoreDifferences + RespectIgnoreDifferences), API defaults (Server-Side Diff), human drift (tighten RBAC + selfHeal + alerts).
  • Put global rules in argocd-cm, application rules go in the Application; track the decline in the number of OutOfSync applications with metrics.
  • Keep prune, and use resource-level Prune=false to protect stateful resources.
or get ≥ 70% in the “Quiz”

Module 7 · Part B: scale, multi-tenancy and security (interview 26–38)

44:00 – 52:00 · App of Apps and ApplicationSet, generators, AppSet security and progressive sync, multi-cluster topology, cluster credentials, AppProject, RBAC and SSO, security hardening, sharding, Repo Server performance, monitoring, supply chain, high availability and disaster recovery
8 minScale → isolate → harden13 questions
Learning objectives
  • Be able to design Argo CD topology, projects and permissions for “dozens of teams and multiple clusters,” and explain the blast radius of each choice.
  • Be able to answer questions about Argo CD's security model: how much privilege it has, who can make it do what, where credentials live, and how to harden it.
  • Be able to say which component is the capacity bottleneck, which metrics to watch, and which parameters to tune.

Browse the questions and focus areas first; click a row to jump to the details.

Q26. What is the difference between App of Apps and ApplicationSet? What scenarios is each suited for?Intermediate
30-second answer

App of Apps: one parent Application syncs a directory whose contents are child Application manifests — explicit, one file per child application, suited for bootstrapping and collections of heterogeneous applications. ApplicationSet: one template + generators automatically produce Applications — suited for homogeneous fan-out (the same application × multiple clusters / environments / tenants / each PR). In production they are often combined: a root app (App of Apps) manages projects and AppSets, and the AppSets generate business applications.

In-depth answer
  • In App of Apps, child application health is not evaluated by default (a custom health check is needed, Q20); deleting the parent application cascades to delete child applications (and their resources).
  • AppSet risks concentrate on changes in generator output (#28): control them with applicationsSync: create-update and preserveResourcesOnDeletion .
  • AppSet means Application manifests no longer appear individually in Git for review — the review object becomes the template and generator parameters, which requires argocd appset generate preview.
Common follow-up questions
  • Can teams write AppSets themselves? An AppSet can generate applications for any project; by default only administrators are allowed to create them; or use AppSet in any namespace + project restrictions.
Bonus points

Give a layering: bootstrap (Argo CD itself) → platform (AppSet: per-cluster infrastructure) → teams (AppSet: per team × environment).

Common wrong answers

“ApplicationSet replaced App of Apps, and the latter is deprecated.”

See Lesson 3 Module 2,Module 3.

Q27. Introduce ApplicationSet generators. What is the difference between Matrix and Merge? Why is goTemplate recommended?Intermediate
30-second answer

Generators: List, Cluster (by cluster Secret and labels), Git (directories / files), SCM Provider (repositories in an organization), Pull Request, Cluster Decision Resource, Plugin; plus the combination generators Matrix (Cartesian product, up to two levels) and Merge (merge by key, override defaults). goTemplate uses Go templates + Sprig functions and supports conditions, defaults and nested structures; combined with missingkey=error it makes typos fail immediately (#27).

generators:
- matrix:
    generators:
    - clusters: {selector: {matchLabels: {env: prod}}}
    - git:
        repoURL: https://github.com/<you>/gitops-lab
        revision: main
        directories: [{path: apps/*/overlays/prod}]
Common follow-up questions
  • How do applications appear automatically when a new cluster is added? Cluster generator + cluster Secret labels; registering a new cluster automatically fans out. Note that the local cluster has no Secret by default, so a label selector cannot select it.
  • How do you exclude specific combinations? Use the generator's selector / templatePatch or a Merge override.
  • Limitations? Matrix only supports combining two child generators; templatePatch it can only be used with goTemplate, and does not support modifying spec.project (official Template docs).
Bonus points

Mention generator polling and webhooks (#29), and API rate limiting of SCM / PR generators (#49).

Common wrong answers

“Matrix pairs two lists in order.”

See Lesson 3 Module 4,Module 5.

Q28. How do you keep ApplicationSet changes from affecting all clusters at once? Explain RollingSync (progressive sync).Advanced
30-second answer

RollingSync groups generated Applications into steps by label (for example dev first, then staging, and prod last, or first a canary cluster); the next step syncs only once the applications in the previous step are all healthy; you can set maxUpdate. It is a Beta feature that needs to be explicitly enabled (applicationsetcontroller.enable.progressive.syncs: "true"); once enabled, the generated applications' sync is controlled by the AppSet (auto-sync is taken over).

strategy:
  type: RollingSync
  rollingSync:
    steps:
    - matchExpressions: [{key: env, operator: In, values: [dev]}]
    - matchExpressions: [{key: env, operator: In, values: [staging]}]
    - matchExpressions: [{key: env, operator: In, values: [prod]}]
      maxUpdate: 25%
In-depth answer
  • It controls the pace at which a single template / Git change advances across applications, not the canary inside a single application (that is Rollouts).
  • From 3.6, step progression relies on annotations (upgrade notes “Progressing through steps now relies on annotation”).
  • Alternative: environment promotion is itself progressive (different directories / revisions), combined with tools such as Kargo.
Common follow-up questions
  • What if an application in a step fails? Subsequent steps do not advance; manual handling is needed; configure notifications.
Bonus points

Split “blast radius control” into three layers: promotion (between environments), RollingSync (between clusters / applications), Rollouts (between Pods); and connect to the Q50 post-mortem.

Common wrong answers

“RollingSync is a Deployment rolling update.”

See Lesson 3 Module 7.

Q29. Multi-cluster topology: one central Argo CD for all clusters, one per cluster, or one per region? How do you choose?Advanced
30-second answer

Hub-spoke (one instance): unified view, unified governance, low operational cost; but the hub holds high-privilege credentials for all clusters (large blast radius), is a single point of failure, needs network access to every cluster's API, and is limited by controller scale. One per cluster: good isolation, pure pull, no cross-network credentials; but governance is scattered, views are scattered, and upgrades happen N times. Compromise: group by region / environment (prod and non-prod separated, one per region), or use an agent-style architecture (centralized control plane, execution plane in each cluster; follow the project's current state).

In-depth answer
  • Decision factors: compliance (production credentials must not leave a certain network), network reachability (private clusters), number and scale of clusters, team structure, failure domain (if the hub fails, no cluster can be deployed to, but running workloads are unaffected).
  • Whichever you choose, Git is the common source of truth; declarative management of ApplicationSets and cluster Secrets keeps the cost of “changing topology” under control.
Common follow-up questions
  • What if the hub goes down? Workloads keep running; restore the hub (DR, Q38), and deploy via break-glass in the meantime.
Bonus points

Be able to connect the “GitOps pull principle” with hub-spoke's “push to remote API” (Q2), and give a phased evolution path.

Common wrong answers

“One Argo CD can manage any number of clusters with no cost.”

See Lesson 4 Module 6 Hub-and-spoke and one Argo CD per cluster.

Q30. argocd cluster add does it do? How do you make the cluster credentials least-privilege?Advanced
30-second answer

It creates, in the target cluster, argocd-manager a ServiceAccount and ClusterRole/Binding (equivalent to cluster admin by default), takes its token, and generates a cluster Secret in the Argo CD namespace (argocd.argoproj.io/secret-type: cluster). Least privilege: grant only the namespaces needed (the cluster Secret's namespaces field + namespace-level Role), allow only the cluster-level resources needed; use short-lived credentials (cloud Workload Identity / exec plugins, such as AKS Entra authentication, EKS IRSA / Pod Identity); use impersonation so that syncs run as the tenant identity.

In-depth answer
  • The cluster Secret itself is the most sensitive object: restrict who can read argocd Secrets in the namespace; Argo CD RBAC's clusters resource controls who can manage cluster entries via the API.
  • Manage cluster Secrets declaratively (Git + a secrets tool); labels are used by the Cluster generator.
  • The controller's cache watches resources within the allowed scope; narrowing the namespace scope also reduces memory (Q34).
Common follow-up questions
  • Why can't the local kind cluster be reached? The 127.0.0.1 address problem (#32).
Bonus points

Be able to say “Argo CD's privileges = the union of privileges of everyone who can make Argo CD do things,” so projects, RBAC and Git branch protection are all part of cluster security.

Common wrong answers

“cluster add just saves the kubeconfig.”

See Lesson 4 Module 5,AKS 8 hours.

Q31. How do you design multi-tenancy with AppProject? What restrictions should one team's project include?Intermediate
30-second answer

One AppProject per team (or one per team × environment): sourceRepos (only allow the team's repositories and reviewed chart repositories),destinations (team namespace prefix × allowed clusters),clusterResourceWhitelist (usually empty),namespaceResourceBlacklist (forbid platform-managed kinds such as ResourceQuota, LimitRange, NetworkPolicy),roles (team roles and CI tokens),syncWindows,orphanedResources,sourceNamespaces (applications in any namespace).

spec:
  sourceRepos: ['https://github.com/acme/team-a-*']
  destinations: [{name: '*', namespace: 'team-a-*'}]
  clusterResourceWhitelist: []
  namespaceResourceBlacklist:
  - {group: '', kind: ResourceQuota}
  - {group: networking.k8s.io, kind: NetworkPolicy}
  roles:
  - name: ci
    policies: ['p, proj:team-a:ci, applications, sync, team-a/*, allow']
Common follow-up questions
  • default How should the default project be handled? Tighten it to allow nothing, so new applications do not get loose permissions by default.
  • What are the risks of project tokens? Long-lived JWTs; set an expiry, rotate regularly; they can be revoked by iat its ID.
Bonus points

Point out that the project boundary is validated by Argo CD, and combine it with Kubernetes RBAC / impersonation and admission policies (Kyverno, Gatekeeper) for defense in depth.

Common wrong answers

“Projects are only for grouping in the UI.”

See Lesson 4 Module 1,Module 2.

Q32. What is the Argo CD RBAC model? How do SSO groups, local accounts and project tokens work together?Intermediate
30-second answer

Casbin policy: p, subject, resource, action, object, allow|deny and g, user or group, role; resources include applications, applicationsets, logs, exec, clusters, repositories, projects, accounts, certificates, gpgkeys, etc.; the object is usually project/application. policy.default is the fallback role,scopes determines which claims are read from the OIDC token as groups. People use SSO groups; automation uses project role tokens or local accounts (apiKey); the admin account is only for break-glass.

In-depth answer
  • v3: logs requires explicit authorization (#35); update/delete no longer inherited by managed resources (#36); the Dex user identifier changes to federated_claims.user_id (#34).
  • Specifying a revision when syncing is treated as override an action (RBAC docs), which can be controlled separately as “whether one can sync to any revision.”
  • Testing: argocd admin settings rbac validate / can Put it into CI.
Common follow-up questions
  • What if deny and allow conflict? Deny takes precedence.
  • Why does a non-existent application return permission denied? To prevent enumeration (#33).
Bonus points

Give a minimum-privilege example of an “on-call role”: get, sync, logs, delete Pods, restart Deployments, but cannot modify the application spec.

Common wrong answers

“Argo CD directly uses Kubernetes RBAC to decide user permissions.”

See Lesson 4 Module 3,Module 4.

Q33. What are the security risks of Argo CD itself? How would you harden a production instance?Advanced
30-second answer

Risks: ① high privileges of the controller over target clusters; ② repo-server executes untrusted templates and plugins (Helm, Kustomize plugins, CMP); ③ cluster and repository credential Secrets; ④ API/UI exposure and weak authentication; ⑤ people who can write to Git indirectly hold deployment permissions. Hardening: SSO + disable admin, minimum RBAC, tighten default projects, project allowlists, network policies (repo-server only egresses to Git, forbidden from reaching cluster APIs and metadata endpoints), no SA tokens mounted into repo-server, TLS, auditing, timely security patch upgrades, restricting exec resource actions, Git branch protection and signature verification.

In-depth answer
  • Security-related changes in v3.x: log and fine-grained RBAC (v3.0), sanitized project API responses (upgrade notes in several versions: “Sanitized project API response”), and in 3.5 repo-server mTLS support and Source Integrity.
  • Auditing: Kubernetes audit logs + Argo CD events (Kubernetes Events on Applications) + Git history.
Common follow-up questions
  • What is the worst-case consequence if Argo CD is compromised? Control over all managed clusters — so splitting across multiple instances and minimal credentials matter (Q29, Q30).
Bonus points

Demonstrate the habit of following the official Security docs and CVE advisories, and include Argo CD upgrades in the monthly patch process.

Common wrong answers

“Argo CD only reads Git, so there are no security risks.”

See Lesson 5 Module 1,Module 8 security review.

Q34. With 2,000 applications and 30 clusters, how do you scale and tune the Application Controller?Advanced
30-second answer

Sharding: increase the controller StatefulSet replicas; clusters are assigned by the sharding algorithm (default legacy, others include round-robin,consistent-hashing etc.; check the feature-maturity docs for maturity levels); increase controller.status.processors (default 20) and controller.operation.processors (default 10); controller.kubectl.parallelism.limit (default 20); use resource.exclusions to reduce cached resource types; adjust timeout.reconciliation and use webhooks; allocate sufficient memory.

In-depth answer
  • A single very large cluster cannot be split across shards → one instance per cluster / per region (Q29).
  • Metrics: argocd_app_reconcile (duration),workqueue_depth,argocd_cluster_api_resource_objects, memory and OOM (#48); argocd admin cluster stats / shards.
  • The v3 default exclusions and ignoring status updates have already reduced a lot of unnecessary reconciliation.
Common follow-up questions
  • Will changing shards cause an interruption? When clusters are reassigned, the new shard needs to rebuild its cache, with a brief delay.
Bonus points

Let data speak: measure first (which cluster has the most resources, which application reconciles slowest), then tune; parameter changes also go into Git.

Common wrong answers

“Change the controller to a Deployment and run 10 replicas” — it relies on sharding and cannot simply be run with multiple replicas.

See Lesson 7 Module 2.

Q35. Why does Repo Server become a bottleneck? How do you optimize for a monorepo scenario?Intermediate
30-second answer

Each revision change requires cloning / fetching and rendering (Helm dependency building, Kustomize, CMP); in a monorepo any commit changes every application's revision, causing everything to re-render. Optimizations: argocd.argoproj.io/manifest-generate-paths annotate to limit relevant paths; scale repo-server horizontally; reposerver.parallelism.limit limit concurrency to prevent OOM; vendor Helm dependencies; adjust timeouts (#43); use webhooks instead of frequent polling; split repos when necessary.

In-depth answer
  • The render cache (Redis) is hit by revision and parameters; the cache expires after 24 hours by default.
  • Large repo cloning: shallow clone / sparse checkout capabilities and disk (emptyDir) size; restarting repo-server loses local clones.
  • In 3.6, argocd app diff --local --server-side-generate the default included files of *.tpl and Chart.lock were added (local preview is more accurate).
Common follow-up questions
  • Does Source Hydrator help? It renders in advance and commits the results, so repo-server only needs to read plain YAML (Beta; it has an extra write-to-Git process).
Bonus points

Metrics: argocd_repo_pending_request_total,argocd_git_request_total, rendering duration.

Common wrong answers

“repo-server is just git clone, it won't be slow.”

See Lesson 7 Module 3.

Q36. How would you monitor Argo CD? Which alerts are essential?Intermediate
30-second answer

Two layers: Platform health (component availability, restarts / OOM, controller work queue depth and reconciliation duration, repo-server pending requests and Git failure rate, cluster connection status argocd_cluster_connection_status, Redis) and delivery health (argocd_app_info the sync_status / health_status labels of the metric: long-term OutOfSync, Degraded, sync failure rate argocd_app_sync_total). Essential alerts: component unavailable, cluster disconnected, application Degraded > N minutes, sync failure, OutOfSync > N hours (drift), certificate / token about to expire.

sum by (dest_server) (argocd_app_info{health_status="Degraded"}) > 0
increase(argocd_app_sync_total{phase=~"Error|Failed"}[15m]) > 0
argocd_cluster_connection_status == 0
Common follow-up questions
  • Which metrics did v3 remove? argocd_app_sync_status,argocd_app_health_status,argocd_app_created_time (Q13).
Bonus points

Combine DORA metrics with Argo CD metrics (deployment frequency = number of successful production syncs; time to restore = Degraded → Healthy duration); for dashboards and alerts see the next course.

Common wrong answers

“Looking at the UI is enough.”

See Lesson 7 Module 4.

Q37. How do you secure the supply chain in GitOps? What does Argo CD provide?Advanced
30-second answer

Chain: source (who can change Git, whether commits are signed) → rendering (chart / dependency sources) → artifacts (image signatures and SBOM) → admission (the cluster rejects unsigned or non-compliant objects). Argo CD: project sourceRepos allowlists, repository credential isolation,Source Integrity (from 3.5 it replaces GnuPG commit signature verification; old configuration still works temporarily, with a warning); image signature verification is delegated to admission control (Kyverno / Sigstore policy-controller / Ratify).

In-depth answer
  • Git: branch protection, required reviews, CODEOWNERS, signed commits, no force push.
  • Charts: mirror to an internal OCI repository and pin versions (Chart.lock).
  • Images: use only digests or immutable tags; cosign signing + admission verification.
  • Argo CD itself: use the officially released signed images and SBOM (the 3.5 release notes mention sbom.tar.gz content changes).
Common follow-up questions
  • Does the OCI generator verify signatures? The docs state that cosign signatures are not yet verified (Generators-OCI).
Bonus points

Reference the SLSA level thinking; draw “who can change production” as a chain and identify the weak links.

Common wrong answers

“The repo is private, so the supply chain is secure.”

See Lesson 5 Module 7.

Q38. How do you do high availability and disaster recovery for Argo CD? If the entire Argo CD namespace is deleted, how do you recover?Intermediate
30-second answer

HA: the official HA manifests / chart HA configuration (multi-replica server and repo-server, Redis HA, controller sharding), PodDisruptionBudget and anti-affinity. DR: almost all of Argo CD's “state” can be rebuilt from Git — bootstrap manifests, projects, AppSets and Applications are all in Git; what needs extra backup is credentials (repositories, cluster Secrets, SSO client secrets) and the secrets-tool keys (Sealed Secrets private keys). argocd admin export / import All configuration and applications can be exported.

In-depth answer
  • Recovery order: install Argo CD (same version) → restore the credential Secrets (from the secret store / ESO) → apply the root app → AppSets regenerate applications → applications re-“claim” existing resources (tracking annotations are still there, so workloads are not rebuilt).
  • Note: during recovery, do not let an AppSet delete applications while its generators are still incomplete (create-update policy, #28).
  • Drill: once a quarter, perform a full recovery on a new cluster and time it.
Common follow-up questions
  • Will workloads be affected? Deleting the Argo CD namespace does not affect running workloads (unless you delete applications with finalizers, which triggers cascading deletion).
Bonus points

Be able to say “Argo CD is not the data plane; an outage only affects the ability to make changes,” and define the RTO target by the time to “restore deployment capability.”

Common wrong answers

“Application data is in Redis, so back up Redis.”

See Lesson 7 Module 1,Module 7.

Four lines of defense for multi-tenancy (Q30–Q33) ① GitBranch protectionCODEOWNERSSigned commitsRequired checks (rendering, policy) ② Argo CD RBACSSO groups → rolessync / logs / execupdate/* · delete/*Project tokens ③ AppProjectsourceReposdestinationsResource allow / deny listssyncWindows ④ KubernetesLeast-privilege cluster credentialsimpersonationAdmission policiesQuotas and network policies ①②③ are validated by Git / Argo CD; ④ is enforced by the API Server — the further right, the harder to bypass
Figure 7-1 Defense in depth: do not rely on just one layer

Scenario 7-1: design self-service onboarding for 40 teams

Requirements: a new team submits one PR to get a namespace, project, CI token, and applications for the dev/staging/prod environments; the platform team reviews only one file.

Key points of the reference answer
  • Team description file teams/team-x.yaml (name, repositories, clusters, quotas, SSO groups).
  • The platform AppSet (the Git file generator reads teams/*.yaml) generates: namespace + quota + network policy (platform project), AppProject, and the team's application AppSet.
  • RBAC: group mappings are written in the project roles; CI tokens are created through a project role and stored in the team's CI secrets.
  • Protection: AppSet create-update + preserveResourcesOnDeletion; team deletion goes through a separate process.

Scenario 7-2: Argo CD slows down before a big sales event

A week before the big sales event there are many releases; in the Argo CD UI, status lags by 5–10 minutes, repo-server occasionally OOMs, and GitHub reports rate limiting. Provide a troubleshooting and scaling plan.

Key points of the reference answer
  • Locate by stage (Figure 4-2): number of Git requests and rate limiting (webhooks,manifest-generate-paths, GitHub App); repo-server pending requests and memory (scale replicas, parallelism limits, vendoring); controller queue (processor count, sharding).
  • During the sales event, enable sync windows that allow only approved changes; freeze non-essential AppSet changes.
  • Afterwards: write capacity baselines and alert thresholds into the runbook.

Scenario 7-3: the security team requires “Argo CD must not hold cluster-admin on production clusters”

Please give an actionable plan and an impact assessment for existing applications.

Key points of the reference answer
  • Change cluster credentials to namespace scope plus necessary cluster-level read-only access; manage cluster-level resources (CRDs, ClusterRoles) via a separate platform channel (a separate instance or a manually approved pipeline).
  • Enable sync impersonation, mapping each project to a ServiceAccount in the target cluster.
  • Impact: the list of required cluster resources, and sync failures caused by tightened project allowlists (#37) — evaluate first with a dry-run in staging.
or get ≥ 70% in the “Quiz”

Module 8 · Part B: scenario design and incident post-mortems (interview 39–50)

52:00 – 60:00 · 6 platform design questions (multi-team platform, environment promotion, break-glass, CI write-back, preview environments, database migrations) + 6 incident post-mortem questions (accidental AppSet deletion, prune deleting a PVC, secrets in Git, controller OOM, Helm migration, a bad configuration pushed to all clusters at once)
8 minDesign → post-mortem → improvement12 questions
Learning objectives
  • Answer design questions in this order: “requirements and constraints → solution (with a diagram) → key configuration → failure modes and safeguards → evolution.”
  • Answer post-mortem questions in this order: “timeline → impact → root cause (5 Whys, distinguishing trigger factors from root causes) → mitigation → long-term improvements (prevention / detection / mitigation) → metrics,”focusing on facts, not blame.
  • Every answer should be tied to specific issue numbers and configuration in Part A.

Browse the questions and focus areas first; click a row to jump to the details. [Design] and [Post-mortem] mark the question type.

Q39. [Design]Design a GitOps platform for 50 teams and 10 clusters (3 regions, dev/staging/prod).Advanced
30-second answer

Topology: separate Argo CD instances for production and non-production (one production instance per region) to reduce blast radius; repositories: a platform repo (bootstrap, projects, clusters, platform components) + team config repos; onboarding: team description file → platform AppSet generates namespaces, projects and team applications; governance: SSO groups → project roles, project allowlists, sync windows, notifications; delivery: PR promotion + Rollouts; observability: metrics, alerts, DORA.

In-depth answer
  • Bootstrap chain: install Argo CD with Helm → self-managed application → root app → platform AppSet (Cluster generator × platform components) → team AppSet (Git file generator × environments).
  • Cluster registration: declarative cluster Secrets (ESO pulls from the secret store), with labels env,region driving the generators.
  • Security: least-privilege cluster credentials for production instances + impersonation; default lock down projects; disable admin.
  • Capacity: applications per instance < estimated threshold, controller sharding, repo-server HPA, webhooks.
  • Failure modes: accidental AppSet deletion (create-update), bad configuration fanning out (RollingSync / batched promotion), Argo CD outage (DR, break-glass).
Common follow-up questions
  • Why not a single instance? Centralized credentials, upgrades and failures affect all environments, and a scale ceiling (Q29).
Bonus points

Give an evolution path (pilot with 1 instance → split production → regionalize) and platform SLOs (availability of deployment capability, P95 change-to-effect time).

Common wrong answers

Talking only about tools and not the organization: no onboarding process, permissions or runbook.

Q40. [Design]How do you implement environment promotion from dev → staging → prod? Who changes Git?Advanced
30-second answer

CI only builds and pushes immutable images, and updates dev the image tag in the environment overlay (a direct commit or an auto-merged PR). Promotion = a PR that copies the version already validated in the previous environment (image digest, chart version, configuration) into the next environment's directory, carrying validation evidence (tests, analysis results), with merging controlled by gates (review, sync windows). Tools: scripts / bots that generate PRs, Kargo (promotion orchestration), Image Updater (dev only).

In-depth answer
  • “What is promoted”: ideally a versioned “release unit” (image + configuration), rather than copying field by field.
  • Environment-specific configuration (replica count, resources, domain names) stays in each environment's overlay and does not take part in promotion.
  • Rollback granularity = promotion PR granularity (Q22).
  • Rollouts does canaries within an environment; RollingSync batches across clusters (Q28).
CI build → image@sha256 → PR: overlays/dev → auto-merge → tests → promotion PR: overlays/staging → analysis → promotion PR: overlays/prod (approval + window)
Common follow-up questions
  • Why not promote with branches? See Q4.
  • How do you avoid two promotions modifying the same file at the same time? One file per application, serialize the bots, and retry with rebase.
Bonus points

Put promotion evidence (links to test reports, AnalysisRun results) in the PR description to satisfy audits.

Common wrong answers

“Image Updater automatically updates all environments” — production lacks gates.

See Lesson 6 Module 7 Environment promotion.

Q41. [Post-mortem]The path of an ApplicationSet's Git generator was changed incorrectly, and within 30 seconds 12 production applications and their workloads were deleted. Please write a post-mortem.Advanced
30-second answer

Trigger: a refactoring PR changed directories: [{path: apps/*/overlays/prod}] to a non-existent path; the review only looked at the diff, not the generated result. Mechanism: the generator returns empty → default sync policy deletes all generated Applications → the resource finalizer cascades to delete workloads (#28). Mitigation: revert the PR → the root app recreates the AppSet → applications resync; stateful data is restored from backups. Improvements: applicationsSync: create-update + preserveResourcesOnDeletion: true, in CI argocd appset generate compare the generated results and block the merge when the count drops sharply; production AppSet changes require platform approval.

In-depth answer
  • Timeline: merge → root app syncs the AppSet (automatic) → AppSet controller reconciles → deletion → alerts (applications Missing / service 5xx) → discovery → revert → recovery.
  • 5 Whys: Why was it deleted? The policy allowed deletion. Why was the generator empty? Wrong path. Why was it not caught? The review object did not include the generated result. Why could it go straight to production? One AppSet managed all environments.
  • Detection improvement: alert on “sharp drop in the number of Applications” (count(argocd_app_info) rate of change).
  • Mitigation improvements: split AppSets by environment, review prod separately; RollingSync.
Common follow-up questions
  • Why not just remove the finalizer? That would leave orphaned resources when applications are deleted; after weighing the trade-offs, the chosen approach is the AppSet-level preserveResourcesOnDeletion.
Bonus points

Point out that this is a typical case of “changes to control-plane configuration also need progressive rollout.”

Common wrong answers

“The developer was careless; tell them to be careful next time” — no systemic improvement.

Q42. [Post-mortem]Auto-sync + prune deleted the production database's PVC. Please write a post-mortem.Advanced
30-second answer

Trigger: a chart upgrade changed the StatefulSet's volumeClaimTemplates to a separate PVC manifest and renamed it (or Kustomize's namePrefix changed); the old PVC disappeared from the desired state → automatic prune deleted it → the StorageClass's reclaimPolicy: Delete reclaim policy deleted the underlying disk. Mitigation: restore from snapshots / backups. Improvements: add argocd.argoproj.io/sync-options: Prune=false,Delete=false (or Prune=confirm), for production StorageClasses use Retain, review deletions in the diff before pruning, manage databases with an operator and apply them separately, and rehearse backup and restore.

In-depth answer
  • Detection: a PVC deletion appearing in the diff before sync should trigger manual confirmation (Prune=confirm which will make the sync stop at waiting for pruning confirmation of …).
  • PruneLast does not prevent deletion; it only changes the order.
  • A name change that leads to “delete the old, create the new” is one of the most common data-loss patterns in GitOps.
Common follow-up questions
  • Why not globally disable prune? It accumulates orphaned resources (#23); resource-level protection is more precise.
Bonus points

Propose an admission policy: reject deletion of PVCs that carry the data-critical=true label, unless they carry an approval annotation.

Common wrong answers

“Argo CD has a bug” — the behavior matches the configuration.

Q43. [Post-mortem]A database password was committed in plaintext to the GitOps repo and pushed to GitHub. How do you handle it?Advanced
30-second answer

Order: ①rotate immediately the password (assume it has leaked; change the password first, then clean up the history) → ② assess the exposure (repository visibility, forks, CI logs, Argo CD render cache and argocd app manifests readers of) → ③ fix the desired state (switch to SealedSecret / ExternalSecret) → ④ clean up history (git filter-repo, notify all clones to re-clone; contact the hosting platform to clean cached commit views) → ⑤ improvements: push protection / secret scanning (GitHub secret scanning push protection, pre-commit hooks), scanning gates in CI, and allow only encrypted-format Secrets.

In-depth answer
  • Argo CD side: Secret resources are masked in the UI, but plaintext exists in rendered results and Redis — after rotation, run a hard refresh; check who has applications, get.
  • Do not just “delete the file and commit again” — the history remains.
  • Record: the exposure time window and the results of access log review (database auditing).
Common follow-up questions
  • Do you still need to rotate for a private repo? Yes — everyone with read access (and their devices, CI) is part of the exposure surface.
Bonus points

Use “ease of rotation” as a criterion for choosing a secrets approach (Q5): ESO + a secret store makes rotation a routine operation.

Common wrong answers

“Just git revert.”

Q44. [Post-mortem]After onboarding 3 new clusters, application-controller OOMs every 20 minutes and all application statuses are Unknown for 2 hours. Please write a post-mortem.Advanced
30-second answer

Mechanism: the controller caches almost all resources for each cluster (#48); the new clusters have huge numbers of objects (tens of thousands of Events, ReplicaSet history, some operator's CRs); a single shard's memory exceeds the limit → OOM → after restart, all cluster caches are rebuilt → OOM again, in a loop. Mitigation: temporarily raise the memory limit, set on the new clusters resource.exclusions or narrow the namespace scope, and add shard replicas. Improvements: a cluster onboarding checklist (argocd admin cluster stats estimate), capacity alerts (memory > 80%, restart count), sharding strategy, and separate instances for very large clusters.

In-depth answer
  • Why 2 hours: in the OOM loop every restart must re-list/watch all clusters; alerts were only on “application Degraded,” not on controller health.
  • Improvement metrics: cached object count per cluster (argocd_cluster_api_resource_objects), controller memory, reconciliation duration P95.
  • Business impact: workloads were not affected; what was affected is deployment capability and visibility — make this clear in the post-mortem.
Common follow-up questions
  • How did v3 help? Default exclusions and ignoring status updates reduce reconciliation and memory pressure, but they cannot replace capacity planning.
Bonus points

Propose: “new clusters first join a shadow shard / read-only applications, are observed for 24 hours, and only then migrate into the production instance.”

Common wrong answers

“Remove the limit.”

Q45. [Design]Design the emergency fix (hotfix) and break-glass process under strict GitOps.Intermediate
30-second answer

Default path: emergency PR (a predefined fast lane: one on-call reviewer + required checks) → merge → webhook triggers immediate sync → verify; the target is to finish within 10 minutes. Break-glass path (Argo CD or Git unavailable, or inside a freeze window): an authorized on-call role temporarily turns off auto-sync / selfHeal for the target application (or enables the window manualSync), performs a controlled manual change, and records it in the incident ticket; within 24 hours after recovery, backfills Git, restores automation, and reviews it in the post-mortem.

In-depth answer
  • Permissions: the break-glass role is defined separately (RBAC allows applications, update for a specified project); it is not assigned by default and is granted temporarily through approval (JIT).
  • Technical safeguards: the sync window's manualSync (#44),argocd app set --sync-policy none usage records, and Kubernetes audit logs.
  • Drills: a break-glass drill once a quarter, including the “Argo CD unavailable” scenario.
Common follow-up questions
  • How do you keep break-glass from becoming the norm? Track the number and causes of break-glass events as input for platform improvements (for example, if the fast lane is too slow).
Bonus points

Treat break-glass as “declarative” too: pre-written runbooks, pre-defined roles and commands.

Common wrong answers

“In an emergency, kubectl edit directly, and forget about it afterwards.”

Q46. [Design]CI needs to write new image tags back to the GitOps repo. How do you avoid concurrent conflicts, infinite triggering, and over-broad permissions?Intermediate
30-second answer

Separate repositories (the application code repo's CI writes to the config repo, avoiding write-backs triggering its own CI); a bot identity (GitHub App, with write permission only on specific paths of the config repo, or only able to open PRs); concurrency: one file per service + before writing back, git pull --rebase retry, or use a serial queue; idempotency: compare the current value before writing; the commit message includes the source commit SHA and the pipeline link.

for i in 1 2 3 4 5; do
  git pull --rebase -q && yq -i ".images[0].newTag = \"$TAG\"" apps/podinfo/overlays/dev/kustomization.yaml
  git diff --quiet && exit 0                                   # already at the target value: idempotent
  git commit -qam "podinfo dev -> $TAG (src $GITHUB_SHA)" && git push -q && exit 0
  sleep $((i*2))
done; exit 1
Common follow-up questions
  • How does CI know the deployment succeeded? argocd app wait --health --sync (a read-only token), or subscribe to notifications / commit status.
  • Push directly vs open a PR? dev: push directly (fast); staging/prod: open a PR (gate).
Bonus points

Mention that Argo CD Image Updater or Kargo can replace a home-written script, but they likewise must handle write-back credentials and branch protection (#46).

Common wrong answers

“CI force-pushes to main with a personal PAT.”

See Lesson 6 Module 1,GitHub 8 hours.

Q47. [Design]Automatically create a preview environment for each Pull Request, and control costs and cleanup.Intermediate
30-second answer

An ApplicationSet's Pull Request generator (GitHub / GitLab, etc.) generates Applications for open PRs with a specific label: namespace preview-pr-{{.number}}, image tag pr-{{.head_short_sha}}, domain name pr-{{.number}}.preview.example.com; after the PR is closed or merged, the generator no longer returns it and the Application is deleted (here the sync policy must allow deletion).

In-depth answer
  • Cost: namespace quotas, TTL (PRs older than N days are labeled and automatically closed), nightly scale-down, shared database instance + an independent schema per PR.
  • Security: generate only for internal branches / labeled PRs (fork PRs may inject malicious manifests); preview project permissions are restricted.
  • Performance: PR generator polling is subject to API rate limiting (#49); use webhooks.
  • Image readiness: apply the label to trigger only after the CI build completes, to avoid ImagePullBackOff.
Common follow-up questions
  • Why use the sync policy here while production uses create-update? Deleting preview environments is the expected behavior; deletion in production requires a manual process (#28).
Bonus points

Write the preview URL back into the PR (a notification or CI comment).

Common wrong answers

“One cluster per PR.”

See Lesson 3 Module 6.

Q48. [Post-mortem]Migrating a service deployed with helm install to Argo CD caused a 15-minute outage. Please write a post-mortem and give the correct migration steps.Advanced
30-second answer

Common cause: the Argo CD application's releaseName differs from the original Helm release name → the rendered resource names differ → the sync created a new set of resources, and the prune / manual helm uninstall deletion removed the old set; traffic was interrupted while the new Service selector / Ingress was not ready. Correct steps: ① set helm.releaseName to the same as the original release, and confirm argocd app diff only label / annotation differences; ② manual sync (Argo CD takes over the same-named resources and writes tracking annotations); ③ confirm Synced/Healthy; ④ delete Helm's release Secret (sh.helm.release.v1.*) rather than not helm uninstall; ⑤ enable auto-sync.

In-depth answer
  • Timeline and detection: the outage was found by 5xx alerts; a “pre-migration diff review” checkpoint was missing.
  • Helm hook differences: the original post-install Job becomes a PostSync hook in Argo CD and may run again (Q24).
  • Compared with Flux: helm-controller can take over the release directly (Q11).
Common follow-up questions
  • How do you migrate 100 releases in bulk? Use a script to generate Applications (releaseName, with values from helm get values), diffing and syncing batch by batch.
Bonus points

Emphasize the migration principle: “the diff must be zero (or explainable) before syncing.”

Common wrong answers

“Run helm uninstall first, then let Argo CD deploy.”

Q49. [Design]How do database schema migrations for stateful services work with GitOps?Intermediate
30-second answer

Migrations are versioned artifacts (migration scripts are in the image). Execution options: a PreSync hook Job (simple, tied to the sync) or a CR from a database operator / dedicated migration tool (decoupled, observable). Principles: backward-compatible expand / contract, idempotent, retryable, with timeouts (#19), backup before migration, and migrations and code released in two versions (first expand the schema, then release code that uses the new schema, and finally contract).

In-depth answer
  • Failure handling: hook fails → sync fails → Deployment is not updated (old code is still compatible); SyncFail hook alerts.
  • Multiple replicas / multiple clusters: a migration must run only once — place it in an application in a single “primary” environment, or use a database lock to guarantee a single execution.
  • Rollback: code can be rolled back; the schema is usually fixed forward.
Common follow-up questions
  • What about long-running migrations (hours)? Do not put them in a sync hook; use a separate Job / operator and track asynchronously, and switch code via feature flags.
Bonus points

Expose migration status as a health signal (custom health check), so that RollingSync / promotion waits for it.

Common wrong answers

“Migrate automatically at application startup” — concurrent migrations across replicas, and rollbacks are difficult.

Q50. [Post-mortem]A faulty NetworkPolicy was pushed to all 10 clusters at once through the platform ApplicationSet, leaving all services unable to reach the database for 40 minutes. Please write a post-mortem.Advanced
30-second answer

Mechanism: the platform components' AppSet fans out to all clusters via the Cluster generator, with auto-sync and no batching, so a single commit reaches all clusters within minutes (GitOps “efficiency” became “blast radius”). Mitigation: revert → thanks to webhooks, rollback is also quick; but because Argo CD itself is also affected by the policy (if the policy blocks Argo CD's traffic to Git or the API), recovery requires break-glass. Improvements: make platform changes progressive too (RollingSync: canary cluster → non-production → production in batches), validate connectivity for policy-type changes first on a canary cluster (PostSync smoke tests), set exemptions for Argo CD's own network paths, and have sync windows avoid peak hours.

In-depth answer
  • 5 Whys: Why did all clusters break at once? No batching. Why did review not catch it? No connectivity test. Why was recovery slow? Argo CD's own namespace was also affected by the policy, and break-glass had not been rehearsed.
  • Detection: service-level SLO alerts + a correlation alert for “error rate rising within 5 minutes after a platform application sync.”
  • Metrics: change blast radius (number of clusters affected by a single sync), and time to recovery.
Common follow-up questions
  • RollingSync is Beta — can it be used in production? It can be evaluated for use; or achieve batching with “per-environment AppSets + promotion PRs” (Q40).
Bonus points

Summarize the three layers of blast radius control (Q28) and explain which layer was missing this time.

Common wrong answers

“GitOps is not suitable for platform components.”

Answer skeleton for post-mortem questions (Q41–Q44, Q48, Q50) TimelineTrigger → discovery→ mitigation → recovery Impactusers / data / durationDeployment capability vs data plane Root causeMechanism (Part A numbering)5 Whys · systemic ImprovementsPrevention · detectionMitigation · drills MetricsMTTR · blast radiusRecurrence of similar incidents The common pattern of GitOps incidentsWrong desired state (a bad change in Git) × automation amplification (auto-sync / generators / prune) × lack of batching and gatesFixes also go through GitOps: a revert is amplified just as quickly — this is a strength, provided Argo CD itself is not affectedImprovement priority: blast radius control > automated detection > manual review
Figure 8-1 Focus on facts, not people: every improvement should be a systemic configuration, check or process

Scenario 8-1: design a “change safety net” for the Argo CD platform

Over the past six months there were 3 incidents amplified by GitOps (similar to Q41, Q42, Q50). Design a set of CI checks and Argo CD configuration to serve as the default safety net for all GitOps repositories.

Key points of the reference answer
  • CI: render all applications (kustomize / helm template / argocd appset generate), schema validation (kubeconform), policy checks (Kyverno CLI / conftest: forbid deleting resources with critical labels, forbid namespace: '*'), a generated-output diff summary (counts of added / deleted / modified resources) posted to the PR; a deletion count above the threshold requires additional approval.
  • Argo CD: AppSet create-update + preserveResourcesOnDeletion, stateful resources Prune=false,FailOnSharedResource, RollingSync / per-environment AppSets, sync windows, Notifications.
  • Monitoring: alerts on a sharp drop in application count, Degraded count and sync failure rate.

Scenario 8-2: the interviewer gives you 15 minutes: Argo CD is entirely unavailable, and production needs an urgent fix

The Argo CD namespace became unavailable due to a bad Helm upgrade; a production service needs an environment variable changed immediately.

Key points of the reference answer
  • First assess: the time to restore Argo CD (helm rollback Argo CD itself) vs the urgency of the emergency change.
  • If it must be fixed first: commit the fix in Git (keeping the source of truth) → use the break-glass role to kubectl apply apply it directly to the rendered result (kustomize build) → record it.
  • After Argo CD is restored: confirm the application is Synced (because Git already contains the fix, so it will not be reverted).
  • Post-mortem: why was the upgrade of the self-managed Argo CD not rehearsed on a staging instance (Q13)?

Scenario 8-3: give your “GitOps maturity” assessment checklist

You have just joined a company and need to assess its GitOps practices within two weeks and provide a roadmap.

Key points of the reference answer
  • Dimensions: repositories and promotion (Q4, Q40), level of automation (manual / auto-sync / selfHeal), secrets (Q5), multi-tenancy and permissions (Q31, Q32), blast radius control (Q28), observability (Q36), DR (Q38), upgrade cadence (Q13), incidents and break-glass process (Q6, Q45).
  • Score each dimension 0–3, giving evidence (configuration, metrics, interviews) and 3-month / 6-month targets.
or get ≥ 70% in the “Quiz”

Issue cheat sheet + interview flash cards

50 “error / symptom → first diagnostic command → common fix” entries · 50 one-line key-point cards · printable
Post-class

A · Quick reference for 50 production issues

Filter by keywords (for example commit SHA,allowed destinations,Too long,hook,duplicate,permission denied,decrypt,cached,OOM). Click a number to jump to the details in the corresponding module.

B · 50 interview question flash cards

First look at the question and recall the answer yourself, then expand to compare with the one-line key point; for details, return to the “interview question details” in the corresponding module.

General command card

Check application status

argocd app get APP --refresh            # re-compare
argocd app get APP --hard-refresh       # discard the manifest cache (#43)
argocd app get APP --show-operation     # latest operation and message
kubectl -n argocd get application APP -o jsonpath='{range .status.conditions[*]}{.type}: {.message}{"\n"}{end}'
argocd app diff APP [--server-side-diff]
argocd app manifests APP [--source live]
argocd app resources APP

Sync and operations

argocd app sync APP [--prune] [--async]
argocd app wait APP --sync --health --timeout 300
argocd app terminate-op APP             # #19 #20
argocd app rollback APP ID              # requires auto-sync to be turned off first (Q22)
argocd app delete APP --cascade=false   # keep resources (Q25)
argocd proj windows list PROJ           # #44

Repositories, clusters and certificates

argocd repo list; argocd repo get URL --refresh hard
argocd cert list; ssh-keyscan HOST | argocd cert add-ssh --batch
argocd cert add-tls HOST --from ca.pem
argocd cluster list; argocd cluster set OLD --name lab2
kind get kubeconfig --name lab2 --internal     # #32
argocd admin cluster stats -n argocd

Permissions

argocd account get-user-info
argocd account can-i sync applications 'team-a/*'
argocd admin settings rbac can SUBJ ACTION RES OBJ --namespace argocd
argocd admin settings rbac validate --namespace argocd
argocd proj get PROJ

ApplicationSet

argocd appset generate appset.yaml -o yaml     # preview without applying (#26 #27 #28)
argocd appset get NAME
kubectl -n argocd logs deploy/argocd-applicationset-controller --tail=50

Component logs and configuration

kubectl -n argocd logs deploy/argocd-repo-server --tail=80     # rendering
kubectl -n argocd logs sts/argocd-application-controller --tail=80   # compare / sync
kubectl -n argocd logs deploy/argocd-server --tail=80          # API / RBAC
kubectl -n argocd get cm argocd-cm argocd-rbac-cm argocd-cmd-params-cm -o yaml
kubectl -n argocd rollout restart deploy/argocd-server        # restart after params are changed

Condition / message ↔ issue number

Message fragment (v3.6.1)LocationIssue
Failed to load target state: failed to generate manifest for source N of MComparisonError#7 #8 #9 #42 #43
do not match any of the allowed destinations / application repo … is not permittedInvalidSpecError#10 #11
Namespace for … is missing.InvalidSpecError#18
one or more objects failed to apply / one or more synchronization tasks are not validOperation status#15 #16 #17 #37
waiting for completion of hook … / waiting for healthy state of …Operation status (Running)#19 #21
another operation is already in progressCLI / API#20
… is part of applications … and …SharedResourceWarning#24
Unable to delete application resources:DeletionError#25
contains applications with duplicate name / failed to execute go template / references project … which does not existAppSet ErrorOccurred#26 #27 #30
there are no clusters with this nameInvalidSpecError#31
permission denied: resource, action, object, sub: …, iat: …CLI / API#33 #35 #36
resource :Kind is not permitted in project / namespace … is not permitted in projectSync validation#37
… is not permitted to use project …Applications in any namespace#38
Manifest generation error (cached)ComparisonError#43
cannot sync: blocked by sync window / Sync operation blocked by sync windowCLI / operation status#44

Comprehensive practice + mock interview

8 mixed fault scenarios (look at the symptoms first, judge for yourself, then expand the answer) · full mock interview drawing 10 random questions from 50 · course exam
Post-class ≈ 40 minutes

I. Comprehensive fault drills

Each scenario combines several Part A issues. First write down your first diagnostic command and your judgment, then expand the answer.

Scenario 1: Day one of a new team onboarding: not a single application starts, and the messages all differ
team-c-api:   InvalidSpecError  application references project team-c which does not exist (AppSet)
team-c-web:   ComparisonError   … unable to resolve 'master' to a commit SHA
team-c-jobs:  InvalidSpecError  application repo git@github.com:acme/team-c-jobs.git is not permitted in project 'team-c'

Answer: The project synced after the AppSet (#30) → add the project sync-wave: "-1"; the repo's default branch is main (#7); the project lists an HTTPS URL while the application uses SSH (#11), and SSH also needs known_hosts (#5) → standardize the whole organization on HTTPS + a GitHub App credential template (#4).

Scenario 2: One week after upgrading to v3: developers cannot see logs, on-call cannot delete Pods, all alert rules have stopped working, and after cleaning up Git, resources remain in the cluster
permission denied: logs, get, team-a/podinfo-dev, sub: alice, iat: …
permission denied: applications, delete/Pod/…, team-a/podinfo-dev, …
Prometheus: argocd_app_health_status has no data
kubectl get cm old-flags -n podinfo-dev → still exists

Answer: Log RBAC (#35), fine-grained permissions not inherited (#36), metrics removed and replaced with argocd_app_info (Q13, Q36), and the first sync after switching to annotation tracking included deletions, causing orphans (#50) → sync all applications once after the upgrade, and manually clean up the orphans. Lesson: check item by item against the Detection list in the upgrade notes.

Scenario 3: Before a big sales event: pushes take 10 minutes to take effect, repo-server restarts, and GitHub returns 429
argocd-repo-server-…  OOMKilled
ComparisonError … Manifest generation error (cached): … context deadline exceeded
GitHub: API rate limit exceeded (PR generator)

Answer: Render timeouts are cached (#43) → hard refresh, vendor Helm dependencies, adjust timeouts and reposerver.parallelism.limit, scale replicas; polling pressure (#49) → webhooks,manifest-generate-paths, GitHub App; the wait chain from push to effect (#29, Figure 4-2).

Scenario 4: A service stays OutOfSync and its Pods are created and deleted every few minutes
argocd app diff: replicas 3 ↔ 8; istio-proxy container difference
selfHeal: true; HPA minReplicas 3 maxReplicas 10
argocd_app_sync_total +30 per hour

Answer: Git declares a field owned by the HPA + webhook injection (#13) → remove replicas from Git, use ignoreDifferences + RespectIgnoreDifferences=true; default-value differences use Server-Side Diff (#14).

Scenario 5: The release is stuck for 40 minutes, CI reports an error, and eventually the Ingress is found to be spinning forever
CI: rpc error: code = FailedPrecondition desc = another operation is already in progress
Message: waiting for completion of hook batch/Job/db-migrate
(after terminating and fixing) networking.k8s.io  Ingress  …  Progressing

Answer: The migration Job has no timeout (#19) → terminate-op and add activeDeadlineSeconds; CI should not actively sync (#20); the Ingress controller in kind / the new cluster did not write back an address (#21).

Scenario 6: After the second cluster is onboarded, all lab2 applications are Unknown; after fixing that, syncing reports a permission error
argocd cluster list: https://127.0.0.1:41893  Unknown  … connection refused
InvalidSpecError … there are no clusters with this name: lab2
(after the fix) resource :Namespace is not permitted in project team-a

Answer: kind's host address (#32) → --internal kubeconfig; the cluster name is kind-lab2 (#31) → argocd cluster set … --name lab2; the chart includes a Namespace while the project forbids cluster-level resources (#37) → use CreateNamespace=true or create it at the platform layer.

Scenario 7: After migrating to Sealed Secrets and Image Updater: the password is not updated, and the image is not updated automatically either
SealedSecret event: Resource "db-cred" already exists and is not managed by SealedSecret
another namespace: Failed to unseal: no key could decrypt secret (password)
The Application has the argocd-image-updater.argoproj.io/image-list annotation; podinfo is a plain YAML directory

Answer: The old Secret was not taken over (#40); the ciphertext was copied to another namespace / cluster (#39); Image Updater v1.x uses ImageUpdater a CR and does not support plain YAML applications (#46) → switch to a Kustomize overlay.

Scenario 8: Friday evening: sync is rejected, notifications are not sent, and the team wants to “kubectl change it first and deal with it later”
cannot sync: blocked by sync window
podinfo-prod Degraded for 25 minutes, no Slack messages
Someone ran kubectl set env … ; it was reverted 2 minutes later

Answer: A deny window (#44) → break-glass process (Q45: temporarily manualSync, record, backfill); notifications lack the subscription annotation (#47); selfHeal reverting manual changes is GitOps' expected behavior (Q6) — an emergency PR should be submitted instead.

II. Full mock interview (10 questions drawn at random from 50)

Each question has a 2-minute countdown: first answer verbally (you can write key points in the text box), then expand the reference answer and self-rate “answered / partial / don't know.” At the end, this round's score is shown, along with the cumulative mastery rate by module. Self-assessment results are saved in this browser.

III. Open-ended self-test (6 questions)

  1. Draw one reconciliation loop (Repo Server → Controller → Sync / Health → write back), and on each stage mark at least two Part A issue numbers.
  2. Without looking at any material, write out the 6 breaking changes in the 2.14 → 3.0 upgrade notes, and give one detection command or configuration for each.
  3. Write a “production Application template” for your team, and explain which problem each sync option and annotation solves.
  4. Give a selection matrix for Argo CD vs Flux (at least 6 dimensions), and explain under what conditions you would change your choice.
  5. Choose one post-mortem question from Q41–Q50 and write a complete incident post-mortem (timeline, impact, 5 Whys, action items, metrics).
  6. Design a set of CI checks (rendering, policy, AppSet preview, deletion threshold), and explain which Part A issues they can block.

IV. Course exam (12 questions)

Sources and version notes

Verified: 2026-11-17 · version baseline: Argo CD v3.6.1 · Helm chart argo-cd 10.18.0

Versions and facts

ItemFacts used in this lessonSource (accessed 2026-11-17)
Argo CDv3.6.1 (2026-11-04), v3.6.0 (2026-11-03); concurrently maintained: v3.5.7, v3.4.13; Kubernetes versions tested for 3.6: v1.37, v1.36, v1.35, v1.34argo-cd releases · source code of v3.6.1's docs/operator-manual/tested-kubernetes-versions.md
Helm chartargo/argo-cd 10.18.0 (2026-11-11), appVersion v3.6.1,kubeVersion: ">=1.25.0-0"argo-helm(Chart.yaml)
Error and status messagesText in this lesson marked “source-verified” has been checked word for word against the format strings in the v3.6.1 source: util/argo/argo.go,controller/state.go,controller/sync.go,controller/appcontroller.go,gitops-engine/pkg/sync/sync_context.go,gitops-engine/pkg/health/*.go,applicationset/controllers/applicationset_controller.go,applicationset/utils/utils.go,util/git/client.go,util/app/path/path.go,util/app/discovery/discovery.go,util/rbac/rbac.go,reposerver/repository/repository.go,server/application/application.goargo-cd@v3.6.1
Upgrade notes2.14→3.0 (fine-grained RBAC, log RBAC, default resource.exclusions, metric removal, Dex sub, old repository configuration removed, Helm upgrade, annotation tracking, ignoring status and ignoreDifferences updates), 3.2→3.3 (ApplicationSet CRD requires server-side apply, Helm 3.19.2, Kustomize 5.8.0), 3.4→3.5 (Helm 4.2.0, impersonation extension, SSH known_hosts, GnuPG → Source Integrity, repo-server mTLS), 3.5→3.6 (OpenTelemetry, local include defaults, SSA uses Server-Side Diff, progressive sync relies on annotations, health checks during deletion)Upgrading(source docs/operator-manual/upgrading/)
Default parameterstimeout.reconciliation: 120s,timeout.reconciliation.jitter: 60s; controller.status.processors: "20",controller.operation.processors: "10",controller.kubectl.parallelism.limit: "20",controller.repo.server.timeout.seconds: "60",controller.sharding.algorithm: legacy (round-robin and consistent-hashing are Alpha),reposerver.default.cache.expiration: 24h; ARGOCD_EXEC_TIMEOUT default 90s; Git generator requeueAfterSeconds default 180; progressive sync is Beta and must be explicitly enabledSource docs: argocd-cm.yaml, argocd-cmd-params-cm.yaml, config-management-plugins.md, Generators-Git.md, Progressive-Syncs.md, feature-maturity.md
CLICommands and parameters used in this lesson (argocd appset generate -o,argocd app diff --server-side-diff,argocd app delete --cascade --wait,argocd admin settings rbac can … --namespace,argocd proj windows add --kind --schedule --duration --applications,argocd cluster set --name,argocd repo get --refresh hard ) are all present in the v3.6.1 command reference docs; CLI error exit codes ErrorGeneric = 20source docs/user-guide/commands/
Related projectsArgo Rollouts v1.10.2; Argo CD Image Updater v1.5.0 (README: uses ImageUpdater CR, only supports Kustomize / Helm / Plugin applications); Sealed Secrets v0.41.2 (ErrUnsealFailed,no key could decrypt secret,already exists and is not managed by SealedSecret); External Secrets Operator v2.15.0 (API external-secrets.io/v1,SecretSyncedError); Kargo v1.12.6; Flux v2.10.0; kind v0.33.0 (default kindest/node:v1.37.0); podinfo 6.17.0Each project's GitHub releases and source code

Video verification notes

All videos were verified on 2026-11-17 via the YouTube oEmbed endpoint (https://www.youtube.com/oembed?url=…&format=json), checking titles and channels; oEmbed does not return duration or publication dates, so they are not shown. Verified: Octopus Deploy “5 common Argo CD issues and how to fix them” (za_SNwjXehM), “Why Argo CD Breaks at Scale (and How to Avoid It)” (_vxZgonkCAU); TechWorld with Nana “ArgoCD Tutorial for Beginners | GitOps CD for Kubernetes” (MeU5_k9ssrs), “What is GitOps, How GitOps works and Why it's so useful” (f5EpcWp0THw); DevOps & AI Toolkit “Mastering Argo CD Sync Waves: A Deep Dive into Effective GitOps Synchronization Strategies” (LKuRtOTvlXk), “GitOps Without Pipelines With ArgoCD Image Updater” (avPUQin9kzU), “Argo Rollouts - Canary Deployments Made Easy In Kubernetes” (84Ky0aPbHvY), “Bitnami Sealed Secrets - How To Store Kubernetes Secrets In Git Repositories” (xd2QoV6GJlc), “Manage Kubernetes Secrets With External Secrets Operator (ESO)” (SyRZe5YVCVk); Codefresh “Argo CD Ignore Differences” (VMvbVF1xEUU); CNCF “Multi-cluster, multi-apps, multi-value deployments using Argo CD Application Sets - Kostis Kapelonis” (7hJvZaqiG5s), “Mastering Efficiency in Argo CD: Scaling Smarter, Not Costlier - Alexander Matyushentsev, Akuity” (bpsclYlGl2s); Ashok Kumar “🔐 ArgoCD User Management & RBAC Explained 👥 | Create Users, Passwords & Okta SSO 🌐” (NPIo1c5LXI8), “🔥 Top10 ArgoCD InterviewQuestions & Answers | GitOps 🚀 Kubernetes 🎯 DevOps” (bpDOtB1Toxk); Akuity “Argo CD Tutorial: App of Apps in 8 Minutes” (2pvGL0zqf9o), “Introducing Kargo with Jesse Suen and Kelsey Hightower” (yaZc0DdeLKk), “Kargo 1.0: Live Demo + GitOps Workflow Panel” (GvGt0yuApvE); Anton Putra “ArgoCD Notifications (Successful/Failed Deployments)” (OP6IRsNiB4w); DevOps Journey “Argo Rollouts in 15 minutes!” (w3xdopP4aEk); Twain Taylor “The 4 key principles of OpenGitOps” (culqnmWWoVs); Trustscrin CloudLab “Argo CD vs Flux Explained: Which GitOps Tool Should You Use?” (qcT5rRSRhoU); Chris Matcham “I Ditched ArgoCD for FluxCD (Here's What Happened)” (SaxkgUyqflc); VMblog “Octopus Deploy’s Dan Garfield on Argo CD, Guardrails, and Octo Doctor | KubeCon NA 2026” (0zHJJDCBmyY). Not found No verified videos specifically covering Ingress redirect loops, known_hosts / private CA, multi-source $values, Server-Side Diff (v3.6), annotations too long, deleting finalizers, kind multi-cluster networking, Applications in any namespace, CMP troubleshooting, cached render errors, sync window break-glass, 3.3 CRD upgrades, Source Integrity and GitOps incident post-mortems were found; the related pages provide storyboard scripts or notes instead. Third-party videos may be based on v2 or reflect an author's or vendor's stance; use them for reference only.

Audio notes

The “Audio” page uses the browser's built-in Web Speech API (Chinese zh-CN, English terms en-US); no data is uploaded, and the course contains no embedded audio. A Chinese voice pack must be installed on the system; without one, read the script directly or pass it to another TTS tool.

Known limitations

  • The command outputs in this lesson have not been run on a real cluster: All “sample outputs” are constructed from the format strings in the v3.6.1 source and the docs; resource names, URLs, times, ports, Pod suffixes and line numbers are examples; the outer wrappers marked “check against actual output” (gRPC rpc error: code = … desc = …, Go TLS / net errors, go-git's authentication required, x/crypto/ssh's knownhosts: key is unknown, Kubernetes API's namespaces "…" not found, Helm / text/template inner wording) vary with version and transport method.
  • The column names and alignment of CLI table output (argocd repo list,argocd cluster list,argocd appset get) are organized from the documentation examples and were not checked word for word against the actual v3.6.1 print format.
  • In #14, argocd app diff the diff format, and in #23 the ignored (requires pruning) message, in #36 the action string format, in #45 the Rollouts output, in #46 the Image Updater logs and CRD resource names, and in #40 the way takeover annotations are written — all follow the current docs of the corresponding project.
  • In #43, when render errors start being cached (the consecutive-failure threshold and cache duration) depends on repo-server parameters; this lesson does not give specific values.
  • The Flux part (Q10–Q12) is based on general descriptions in the official Flux docs (controller composition, impersonation, helm-controller using the Helm SDK); only the v2.10.0 release was verified; UI tools in the Flux ecosystem were not checked one by one.
  • Conservative approach: the specific components and maturity of Argo CD's agent mode are not described (mentioned only as a topology option); Source Hydrator and progressive sync are labeled Beta per the feature-maturity docs; the sharding algorithms round-robin / consistent-hashing are labeled Alpha; Sealed Secrets' default of a new key every 30 days follows the general description in its docs.
  • The organization names, domain names and repository names in the Part B code examples (acme,example.com) are examples.
  • Self-assessment records from mock interviews are stored only in this browser's localStorage and will be lost if site data is cleared.