Skip to content

Commit dfc8baf

Browse files
committed
docs: Add ArgoCD notes
1 parent d2e9b49 commit dfc8baf

File tree

2 files changed

+52
-1
lines changed

2 files changed

+52
-1
lines changed

ArgoCD/README.md

+31-1
Original file line numberDiff line numberDiff line change
@@ -45,4 +45,34 @@ Progressive Delivery is the practice of deploying an application in a gradual ma
4545

4646
- **Blue/Green** - Deploy the new version of the application to a new environment and then switch the traffic to the new environment. This is the most common form of progressive delivery. It is also the most complex to implement. It requires a lot of infrastructure and a lot of testing.
4747

48-
- **Canary** - Deploy the new version of the application to a small subset of users. If the new version is working fine, then deploy it to the rest of the users. This is the most common form of progressive delivery. It is also the most complex to implement. It requires a lot of infrastructure and a lot of testing.
48+
- **Canary** - Deploy the new version of the application to a small subset of users. If the new version is working fine, then deploy it to the rest of the users. This is the most common form of progressive delivery. It is also the most complex to implement. It requires a lot of infrastructure and a lot of testing.
49+
50+
- To make the whole setup declaritive way and make it infrastructure as we deploy ArgoCD Argo CD applications just like any other Kubernetes resource. This is also managed through a git repository.
51+
52+
[Docs](https://argo-cd.readthedocs.io/en/stable/operator-manual/declarative-setup/) for reference.
53+
54+
Samle YAML:
55+
56+
```YAML
57+
apiVersion: argoproj.io/v1alpha1
58+
kind: Application
59+
metadata:
60+
name: nginx-app # This is the name of the application
61+
namespace: argocd
62+
spec:
63+
destination:
64+
namespace: argocd # This is the namespace where the application will be deployed
65+
server: https://kubernetes.default.svc # This is the default server
66+
project: default
67+
source:
68+
path: ./manifest # This is the path where the manifest is present
69+
repoURL: https://github.com/sarafpradumna/argo-test # This is the repo where the manifest is present
70+
targetRevision: HEAD
71+
syncPolicy:
72+
automated:
73+
prune: true
74+
selfHeal: true
75+
allowEmpty: false #By default it is false
76+
syncOptions:
77+
- CreateNamespace=true # This will create namespace if not present
78+
```

ArgoCD/YAML/declarative.yml

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
apiVersion: argoproj.io/v1alpha1
2+
kind: Application
3+
metadata:
4+
name: nginx-app # This is the name of the application
5+
namespace: argocd
6+
spec:
7+
destination:
8+
namespace: argocd # This is the namespace where the application will be deployed
9+
server: https://kubernetes.default.svc # This is the default server
10+
project: default
11+
source:
12+
path: ./manifest # This is the path where the manifest is present
13+
repoURL: https://github.com/sarafpradumna/argo-test # This is the repo where the manifest is present
14+
targetRevision: HEAD
15+
syncPolicy:
16+
automated:
17+
prune: true
18+
selfHeal: true
19+
syncOptions:
20+
- CreateNamespace=true # This will create namespace if not present
21+

0 commit comments

Comments
 (0)