Argo CD Examples
To follow along Argo CD needs to be installed.
Important
The following can be used to install Argo CD to your cluster:
kubectl create namespace argocd
kubectl apply -n argocd -f https://raw.githubusercontent.com/argoproj/argo-cd/stable/manifests/install.yaml
Or if you need a kubernetes cluster, gitea and argocd on a kind cluster you can check out: _scripts/bootstrap.sh
Jump
to directory: ./helm-values-inside-application/
The helm values are managed inside the Application
:
source:
chart: microservice
repoURL: https://charts.ruan.dev
targetRevision: 3.1.1
helm:
values: |
replicaCount: 1
Jump
to directory: ./helm-values-from-file/
The application is defined in helm-values-from-file/apps/app-dev.yaml
and the values are defined in helm-values-from-file/values-dev.yaml
and argo will monitor this path on git:
source:
path: helm-values-from-file
repoUrl: https://github.com/ruanbekker/argocd-examples
targetRevision: HEAD
helm:
valueFiles:
- values-dev.yaml
Jump
to directory: ./git-and-list-generators/
The application is defined in git-and-list-generators/multiple-git-tags-application.yaml
and listens for applications in apps/
and does the following:
For staging:
- If the commit tag is
staging
it will append astaging-
prefix to the name and deploy to thestaging
namespace in thekind-staging
cluster.
For production:
- If the commit tag is
production
it will append aprod-
prefix to the name and deploy to theprod
namespace in thekind-prod
cluster.