# GitOps CI/CD Implementation using ArgoCD on DigitalOcean

Argo CD follows the **GitOps** pattern of using Git repositories as the source of truth for defining the desired application state. Kubernetes manifests can be specified in several ways:

![](https://tribe-s3-production.imgix.net/Vjgiw1ua8WaP1G1PDyPBJ?w=1000&auto=compress,format&dl align="left")

* [kustomize](https://kustomize.io/) applications
    
* [helm](https://helm.sh/) charts
    
* [ksonnet](https://ksonnet.io/) applications
    
* [jsonnet](https://jsonnet.org/) files
    
* Plain directory of YAML/json manifests
    
* Any custom config management tool configured as a config management plugin
    

Argo CD automates the deployment of the desired application states in the specified target environments. Application deployments can track updates to branches, tags, or pinned to a specific version of manifests at a Git commit.  
  
It is the de factor currently in deploying Applications on Kubernetes. Take Note that you still need a Continuous Integration tool, such as Gitlab to have more flexibility.  
  
  
**Characteristics of the Demo Project:**  
  
\- Demonstrate how to use GitOps in your organization.  
\- Use Terraform for K8s and Spaces in D.O.  
\- Use Kustomize.  
\- Use Helm Charts.  
\- Remote Terraform State  
\- Use HashiCorp Vault for Managing Secrets ( ArgoCD Secrets? / Github Token Secrets ) [https://argo-cd.readthedocs.io/en/stable/operator-manual/secret-management/  
\-](https://argo-cd.readthedocs.io/en/stable/operator-manual/secret-management/￼-) Cert Manager[  
](https://argo-cd.readthedocs.io/en/stable/operator-manual/secret-management/%EF%BF%BC)  
  
Without further ado, let's start.

**Step 1: Provision a K8s Cluster and D.O. Space using Terraform.**  
  
We need to have a Kubernetes Cluster and an object storage to backup our Terraform State File.

[Code HERE](https://github.com/asher-lab/asherl/tree/main/terraform/digitalocean/k8s)

Step 2: Install ARGOCD via HELM Deployment. [ARGOCD](https://github.com/argoproj/argo-helm/blob/master/charts/argo-cd/values.yaml)  
  
Step 3: Refer to the instruction here: [Sample ArgoCD Demo Project](https://github.com/oasisvali/do-k8s-challenge/blob/main/README.md)
