Concepts

App of apps

App of apps is a concept to manage multiple applications in a single Kubernetes cluster.

The Argo CD "App of Apps" pattern is a powerful organizational strategy used in GitOps workflows to manage multiple applications or microservices. Here's a detailed explanation:

What is the Argo CD "App of Apps" Pattern?

The "App of Apps" pattern in Argo CD involves creating a parent application that manages multiple child applications. Each child application can represent a different microservice or component of your system. This pattern leverages Argo CD's ability to recursively manage applications, making it easier to handle complex deployments.

How It Works

  1. Parent Application: You define a parent Argo CD application. This application doesn't directly manage Kubernetes resources but instead manages other Argo CD applications.
  2. Child Applications: Each child application is defined in a separate manifest file. These child applications can be stored in different Git repositories or directories.
  3. Recursive Sync: When the parent application is synced, Argo CD will recursively sync all the child applications, ensuring that the entire system is deployed and updated consistently.

Example

Here's a simplified example of how you might define a parent application and a couple of child applications:

Parent Application (parent-app.yaml)

apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
  name: parent-app
spec:
  project: default
  source:
    repoURL: 'https://github.com/your-org/your-repo'
    path: parent-app
  destination:
    server: 'https://kubernetes.default.svc'
    namespace: default
  syncPolicy:
    automated:
      prune: true
      selfHeal: true

Child Application 1 (child-app1.yaml)

apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
  name: child-app1
spec:
  project: default
  source:
    repoURL: 'https://github.com/your-org/your-repo'
    path: child-app1
  destination:
    server: 'https://kubernetes.default.svc'
    namespace: default
  syncPolicy:
    automated:
      prune: true
      selfHeal: true

Child Application 2 (child-app2.yaml)

apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
  name: child-app2
spec:
  project: default
  source:
    repoURL: 'https://github.com/your-org/your-repo'
    path: child-app2
  destination:
    server: 'https://kubernetes.default.svc'
    namespace: default
  syncPolicy:
    automated:
      prune: true
      selfHeal: true

Benefits

  1. Modularity: Each application can be managed independently, making it easier to handle complex systems.
  2. Scalability: You can scale your deployment strategy by adding or removing child applications without affecting the parent application.
  3. Consistency: Ensures that all applications are deployed in a consistent state, reducing the risk of configuration drift.
  4. Separation of Concerns: Different teams can manage different parts of the system independently, improving collaboration and reducing conflicts.

Copyright © 2025. All rights reserved.