Skip to content

Deploy ArgoCD

Requirements

Configure OIDC

Follow either Azure or Google documentation


Configure Helm files

sed -i "s/AzureADClientSecret/$(argoCdAadClientSecret)/g" Minority/Canary/ArgoCD/ArgoCD-Server/values.yaml

Edit in values.yaml:

configs:
  secret:
    extra:
      oidc.azure.clientSecret: xxx

server:
  ingress:
    ...
    hostname: argocd.minority.com

Edit in dev-values.yaml:

global:
  domain: dev-argocd.minority.com

server: 
  ingress:
    hostname: dev-argocd.minority.com

configs:
  cm:
    url: https://dev-argocd.minority.com/


Deploy Argo CD server Helm chart

helm repo add argo https://argoproj.github.io/argo-helm --force-update

helm upgrade --install \
  minority-argocd argo/argo-cd \
  --namespace argocd \
  --version v7.5.2 \
  -f values.yaml -f dev-values.yaml 

Minority/Canary/ArgoCD/ArgoCD-Server

Creating Applications in ArgoCD

ArgoCD applications are declarative manifests that define the desired state of your Kubernetes resources. ArgoCD automatically reconciles the actual state of your Kubernetes resources with the desired state specified in the application manifests.

App of Apps Pattern in ArgoCD
The app of apps pattern in ArgoCD is a technique for managing a group of applications as a single application.

The app of apps pattern offers a powerful approach to managing complex applications in ArgoCD. It simplifies the deployment process and facilitates the management of applications as a whole.

Creating an App of Apps Using kubectl apply

The rootapp should be created either via a pipeline or using the kubectl apply command using the manifest file, follow these steps:

  1. Ensure kubectl is installed and configured to access your Kubernetes cluster.
  2. Navigate to the directory containing the app of apps manifest you want to apply.
  3. Execute the following command, replacing rootapp-applications-dev.yaml with the actual manifest filename:
##  rootapp for applications in dev environment 
kubectl apply -n argocd -f rootapp-applications-dev.yaml

This command will create an app of apps named rootapp-applications that deploys the applications defined in applications.yaml template with user defined values in Applications/values.yaml file.

Creating Projects in ArgoCD

ArgoCD projects allow you to group applications together and control which namespaces they can be deployed to. Projects also enable defining RBAC policies for applications.

Creating a Project Using kubectl apply

To create a project using the kubectl apply command, follow these steps:

  1. Ensure kubectl is installed and configured to access your Kubernetes cluster.
  2. Navigate to the directory containing the project manifest you want to apply.
  3. Execute the following command, use rootapp-projects.yaml yaml manifest present in Projects directory
##  rootapp for Projects in dev environment 
kubectl apply -n argocd -f rootapp-projects.yaml

References