From b0a22b09a067d140eb1e72e3b0c18ac8ef54f64e Mon Sep 17 00:00:00 2001 From: Alex Collins Date: Thu, 25 Apr 2019 09:04:33 -0700 Subject: [PATCH 01/14] Adds app-of-apps --- README.md | 1 + app-of-apps/manifests.yaml | 90 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 91 insertions(+) create mode 100644 app-of-apps/manifests.yaml diff --git a/README.md b/README.md index 317bef2003..c55612556c 100644 --- a/README.md +++ b/README.md @@ -16,3 +16,4 @@ to explore ArgoCD and GitOps! | [sock-shop](sock-shop/) | A microservices demo application (https://microservices-demo.github.io) | | [plugins](plugins/) | Applications which demonstrate config management plugins usage | | [blue-green](blue-green/) | Demonstrates how to implement blue-green deployment using [Argo Rollouts](https://github.com/argoproj/argo-rollouts) +| [app-of-apps](app-of-apps/) | An application composed of other applications | diff --git a/app-of-apps/manifests.yaml b/app-of-apps/manifests.yaml new file mode 100644 index 0000000000..a5c32804bd --- /dev/null +++ b/app-of-apps/manifests.yaml @@ -0,0 +1,90 @@ +apiVersion: argoproj.io/v1alpha1 +kind: Application +metadata: + name: guestbook +spec: + destination: + namespace: default + server: https://kubernetes.default.svc + project: default + source: + path: guestbook + repoURL: https://github.com/argoproj/argocd-example-apps + targetRevision: HEAD + syncPolicy: + automated: + prune: true +--- +apiVersion: argoproj.io/v1alpha1 +kind: Application +metadata: + name: helm-dependency +spec: + destination: + namespace: default + server: https://kubernetes.default.svc + project: default + source: + path: helm-dependency + repoURL: https://github.com/argoproj/argocd-example-apps + targetRevision: HEAD + syncPolicy: + automated: + prune: true +--- +apiVersion: argoproj.io/v1alpha1 +kind: Application +metadata: + name: helm-guestbook +spec: + destination: + namespace: default + server: https://kubernetes.default.svc + project: default + source: + path: helm-guestbook + repoURL: https://github.com/argoproj/argocd-example-apps + targetRevision: HEAD + syncPolicy: + automated: + prune: true +--- +apiVersion: argoproj.io/v1alpha1 +kind: Application +metadata: + name: kustomize-guestbook +spec: + destination: + namespace: default + server: https://kubernetes.default.svc + project: default + source: + path: kustomize-guestbook + repoURL: https://github.com/argoproj/argocd-example-apps + targetRevision: HEAD + kustomize: + images: + - gcr.io/heptio-images/ks-guestbook-demo:0.3 + syncPolicy: + automated: + prune: true +--- +apiVersion: argoproj.io/v1alpha1 +kind: Application +metadata: + name: kustomize-guestbook +spec: + destination: + namespace: default + server: https://kubernetes.default.svc + project: default + source: + path: kustomize-guestbook + repoURL: https://github.com/argoproj/argocd-example-apps + targetRevision: HEAD + kustomize: + images: + - gcr.io/heptio-images/ks-guestbook-demo:0.3 + syncPolicy: + automated: + prune: true From ffae86b6db664f204ed50358f74de66130dedc7d Mon Sep 17 00:00:00 2001 From: Alex Collins Date: Thu, 25 Apr 2019 11:34:17 -0700 Subject: [PATCH 02/14] fix --- app-of-apps/manifests.yaml | 24 ------------------------ 1 file changed, 24 deletions(-) diff --git a/app-of-apps/manifests.yaml b/app-of-apps/manifests.yaml index a5c32804bd..91e9a9e459 100644 --- a/app-of-apps/manifests.yaml +++ b/app-of-apps/manifests.yaml @@ -47,27 +47,6 @@ spec: targetRevision: HEAD syncPolicy: automated: - prune: true ---- -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: kustomize-guestbook -spec: - destination: - namespace: default - server: https://kubernetes.default.svc - project: default - source: - path: kustomize-guestbook - repoURL: https://github.com/argoproj/argocd-example-apps - targetRevision: HEAD - kustomize: - images: - - gcr.io/heptio-images/ks-guestbook-demo:0.3 - syncPolicy: - automated: - prune: true --- apiVersion: argoproj.io/v1alpha1 kind: Application @@ -82,9 +61,6 @@ spec: path: kustomize-guestbook repoURL: https://github.com/argoproj/argocd-example-apps targetRevision: HEAD - kustomize: - images: - - gcr.io/heptio-images/ks-guestbook-demo:0.3 syncPolicy: automated: prune: true From b3c36c36705b31303da002ae5d29ef5f4cc4acca Mon Sep 17 00:00:00 2001 From: Alex Collins Date: Thu, 25 Apr 2019 11:35:25 -0700 Subject: [PATCH 03/14] fix --- app-of-apps/manifests.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/app-of-apps/manifests.yaml b/app-of-apps/manifests.yaml index 91e9a9e459..b86e66bf1e 100644 --- a/app-of-apps/manifests.yaml +++ b/app-of-apps/manifests.yaml @@ -4,7 +4,7 @@ metadata: name: guestbook spec: destination: - namespace: default + namespace: argocd server: https://kubernetes.default.svc project: default source: @@ -21,7 +21,7 @@ metadata: name: helm-dependency spec: destination: - namespace: default + namespace: argocd server: https://kubernetes.default.svc project: default source: @@ -38,7 +38,7 @@ metadata: name: helm-guestbook spec: destination: - namespace: default + namespace: argocd server: https://kubernetes.default.svc project: default source: @@ -54,7 +54,7 @@ metadata: name: kustomize-guestbook spec: destination: - namespace: default + namespace: argocd server: https://kubernetes.default.svc project: default source: From 520d3767826a9625a0a19649a36ec3253f4236b6 Mon Sep 17 00:00:00 2001 From: Alex Collins Date: Thu, 25 Apr 2019 11:35:48 -0700 Subject: [PATCH 04/14] fix --- app-of-apps/manifests.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/app-of-apps/manifests.yaml b/app-of-apps/manifests.yaml index b86e66bf1e..7ee1f2ad96 100644 --- a/app-of-apps/manifests.yaml +++ b/app-of-apps/manifests.yaml @@ -2,6 +2,7 @@ apiVersion: argoproj.io/v1alpha1 kind: Application metadata: name: guestbook + namespace: argocd spec: destination: namespace: argocd From a1d4b5b9ca1d905e276c557101dd7b968b905e90 Mon Sep 17 00:00:00 2001 From: Alex Collins Date: Thu, 25 Apr 2019 11:36:33 -0700 Subject: [PATCH 05/14] fix --- app-of-apps/manifests.yaml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app-of-apps/manifests.yaml b/app-of-apps/manifests.yaml index 7ee1f2ad96..f9e90396f7 100644 --- a/app-of-apps/manifests.yaml +++ b/app-of-apps/manifests.yaml @@ -19,7 +19,8 @@ spec: apiVersion: argoproj.io/v1alpha1 kind: Application metadata: - name: helm-dependency + name: helm-dependency + namespace: argocd spec: destination: namespace: argocd @@ -37,6 +38,7 @@ apiVersion: argoproj.io/v1alpha1 kind: Application metadata: name: helm-guestbook + namespace: argocd spec: destination: namespace: argocd @@ -53,6 +55,7 @@ apiVersion: argoproj.io/v1alpha1 kind: Application metadata: name: kustomize-guestbook + namespace: argocd spec: destination: namespace: argocd From c1ee86e0ef9f9caab63f0d87487e506f622c3e19 Mon Sep 17 00:00:00 2001 From: Alex Collins Date: Thu, 25 Apr 2019 11:45:23 -0700 Subject: [PATCH 06/14] fix --- README.md | 2 +- app-of-apps/manifests.yaml => applications.yaml | 0 2 files changed, 1 insertion(+), 1 deletion(-) rename app-of-apps/manifests.yaml => applications.yaml (100%) diff --git a/README.md b/README.md index c55612556c..467c4a7b17 100644 --- a/README.md +++ b/README.md @@ -16,4 +16,4 @@ to explore ArgoCD and GitOps! | [sock-shop](sock-shop/) | A microservices demo application (https://microservices-demo.github.io) | | [plugins](plugins/) | Applications which demonstrate config management plugins usage | | [blue-green](blue-green/) | Demonstrates how to implement blue-green deployment using [Argo Rollouts](https://github.com/argoproj/argo-rollouts) -| [app-of-apps](app-of-apps/) | An application composed of other applications | +| [applications.yaml](applications.yaml) | An application composed of other applications | diff --git a/app-of-apps/manifests.yaml b/applications.yaml similarity index 100% rename from app-of-apps/manifests.yaml rename to applications.yaml From 81e808ea74df432b8ed33ebd1791debf47de337a Mon Sep 17 00:00:00 2001 From: Alex Collins Date: Thu, 25 Apr 2019 11:47:39 -0700 Subject: [PATCH 07/14] fix --- README.md | 2 +- applications.yaml => applications/applications.yaml | 0 2 files changed, 1 insertion(+), 1 deletion(-) rename applications.yaml => applications/applications.yaml (100%) diff --git a/README.md b/README.md index 467c4a7b17..f4f247410d 100644 --- a/README.md +++ b/README.md @@ -16,4 +16,4 @@ to explore ArgoCD and GitOps! | [sock-shop](sock-shop/) | A microservices demo application (https://microservices-demo.github.io) | | [plugins](plugins/) | Applications which demonstrate config management plugins usage | | [blue-green](blue-green/) | Demonstrates how to implement blue-green deployment using [Argo Rollouts](https://github.com/argoproj/argo-rollouts) -| [applications.yaml](applications.yaml) | An application composed of other applications | +| [applications](applications/) | An application composed of other applications | diff --git a/applications.yaml b/applications/applications.yaml similarity index 100% rename from applications.yaml rename to applications/applications.yaml From 7796459f6be887e1ff6bf9801ff51eefdcd54880 Mon Sep 17 00:00:00 2001 From: Alex Collins Date: Thu, 25 Apr 2019 11:50:10 -0700 Subject: [PATCH 08/14] fix --- applications/applications.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/applications/applications.yaml b/applications/applications.yaml index f9e90396f7..552f2c28ae 100644 --- a/applications/applications.yaml +++ b/applications/applications.yaml @@ -50,6 +50,7 @@ spec: targetRevision: HEAD syncPolicy: automated: + prune: true --- apiVersion: argoproj.io/v1alpha1 kind: Application From e9150909181e5ddf7e539a23cd451b79b21dd3d6 Mon Sep 17 00:00:00 2001 From: Alex Collins Date: Thu, 25 Apr 2019 11:58:31 -0700 Subject: [PATCH 09/14] k --- applications/applications.yaml | 71 ---------------------------------- 1 file changed, 71 deletions(-) delete mode 100644 applications/applications.yaml diff --git a/applications/applications.yaml b/applications/applications.yaml deleted file mode 100644 index 552f2c28ae..0000000000 --- a/applications/applications.yaml +++ /dev/null @@ -1,71 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: guestbook - namespace: argocd -spec: - destination: - namespace: argocd - server: https://kubernetes.default.svc - project: default - source: - path: guestbook - repoURL: https://github.com/argoproj/argocd-example-apps - targetRevision: HEAD - syncPolicy: - automated: - prune: true ---- -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: helm-dependency - namespace: argocd -spec: - destination: - namespace: argocd - server: https://kubernetes.default.svc - project: default - source: - path: helm-dependency - repoURL: https://github.com/argoproj/argocd-example-apps - targetRevision: HEAD - syncPolicy: - automated: - prune: true ---- -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: helm-guestbook - namespace: argocd -spec: - destination: - namespace: argocd - server: https://kubernetes.default.svc - project: default - source: - path: helm-guestbook - repoURL: https://github.com/argoproj/argocd-example-apps - targetRevision: HEAD - syncPolicy: - automated: - prune: true ---- -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: kustomize-guestbook - namespace: argocd -spec: - destination: - namespace: argocd - server: https://kubernetes.default.svc - project: default - source: - path: kustomize-guestbook - repoURL: https://github.com/argoproj/argocd-example-apps - targetRevision: HEAD - syncPolicy: - automated: - prune: true From 16b3c345ed3a373f4f7832a1e95075b2f63d1de3 Mon Sep 17 00:00:00 2001 From: Alex Collins Date: Thu, 25 Apr 2019 12:00:16 -0700 Subject: [PATCH 10/14] kustomize --- applications/base/guestbook/app-argocd.yaml | 17 +++++++++++++++++ applications/kustomization.yaml | 4 ++++ 2 files changed, 21 insertions(+) create mode 100644 applications/base/guestbook/app-argocd.yaml create mode 100644 applications/kustomization.yaml diff --git a/applications/base/guestbook/app-argocd.yaml b/applications/base/guestbook/app-argocd.yaml new file mode 100644 index 0000000000..2832f0bc8a --- /dev/null +++ b/applications/base/guestbook/app-argocd.yaml @@ -0,0 +1,17 @@ +apiVersion: argoproj.io/v1alpha1 +kind: Application +metadata: + name: guestbook + namespace: argocd +spec: + destination: + namespace: argocd + server: https://kubernetes.default.svc + project: default + source: + path: guestbook + repoURL: https://github.com/argoproj/argocd-example-apps + targetRevision: HEAD + syncPolicy: + automated: + prune: true \ No newline at end of file diff --git a/applications/kustomization.yaml b/applications/kustomization.yaml new file mode 100644 index 0000000000..8820cc80af --- /dev/null +++ b/applications/kustomization.yaml @@ -0,0 +1,4 @@ +apiVersion: kustomize.config.k8s.io/v1beta1 +kind: Kustomization +resources: +- base/guestbook/app-argocd.yaml From 4d8d8726f08a7df8c9fbcf225e29f47e7de9dd9a Mon Sep 17 00:00:00 2001 From: Alex Collins Date: Thu, 25 Apr 2019 13:46:24 -0700 Subject: [PATCH 11/14] fix --- applications/Chart.yaml | 5 +++++ applications/kustomization.yaml | 4 ---- .../guestbook/app-argocd.yaml => templates/guestbook.yaml} | 6 +++--- applications/values.yaml | 5 +++++ 4 files changed, 13 insertions(+), 7 deletions(-) create mode 100644 applications/Chart.yaml delete mode 100644 applications/kustomization.yaml rename applications/{base/guestbook/app-argocd.yaml => templates/guestbook.yaml} (68%) create mode 100644 applications/values.yaml diff --git a/applications/Chart.yaml b/applications/Chart.yaml new file mode 100644 index 0000000000..3510e2a0ad --- /dev/null +++ b/applications/Chart.yaml @@ -0,0 +1,5 @@ +apiVersion: v1 +appVersion: "1.0" +description: Applications +name: applications +version: 0.1.0 diff --git a/applications/kustomization.yaml b/applications/kustomization.yaml deleted file mode 100644 index 8820cc80af..0000000000 --- a/applications/kustomization.yaml +++ /dev/null @@ -1,4 +0,0 @@ -apiVersion: kustomize.config.k8s.io/v1beta1 -kind: Kustomization -resources: -- base/guestbook/app-argocd.yaml diff --git a/applications/base/guestbook/app-argocd.yaml b/applications/templates/guestbook.yaml similarity index 68% rename from applications/base/guestbook/app-argocd.yaml rename to applications/templates/guestbook.yaml index 2832f0bc8a..1fe376bb46 100644 --- a/applications/base/guestbook/app-argocd.yaml +++ b/applications/templates/guestbook.yaml @@ -6,12 +6,12 @@ metadata: spec: destination: namespace: argocd - server: https://kubernetes.default.svc + server: {{ .Values.spec.destination.server }} project: default source: path: guestbook repoURL: https://github.com/argoproj/argocd-example-apps - targetRevision: HEAD + targetRevision: {{ .Values.spec.source.targetRevision }} syncPolicy: automated: - prune: true \ No newline at end of file + prune: true diff --git a/applications/values.yaml b/applications/values.yaml new file mode 100644 index 0000000000..9ad29b7623 --- /dev/null +++ b/applications/values.yaml @@ -0,0 +1,5 @@ +spec: + destination: + server: https://kubernetes.default.svc + source: + targretRevision: HEAD \ No newline at end of file From 7aa35f018cf1fbb075a1a3267b5eba352705c337 Mon Sep 17 00:00:00 2001 From: Alex Collins Date: Thu, 25 Apr 2019 13:48:41 -0700 Subject: [PATCH 12/14] fix --- applications/templates/helm-dependency.yaml | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 applications/templates/helm-dependency.yaml diff --git a/applications/templates/helm-dependency.yaml b/applications/templates/helm-dependency.yaml new file mode 100644 index 0000000000..9c1e4a8771 --- /dev/null +++ b/applications/templates/helm-dependency.yaml @@ -0,0 +1,17 @@ +apiVersion: argoproj.io/v1alpha1 +kind: Application +metadata: + name: helm-dependency + namespace: argocd +spec: + destination: + namespace: argocd + server: {{ .Values.spec.destination.server }} + project: default + source: + path: helm-dependency + repoURL: https://github.com/argoproj/argocd-example-apps + targetRevision: {{ .Values.spec.source.targetRevision }} + syncPolicy: + automated: + prune: true From 1940e66d607a9d6d7fe10859dab1cf99cc2c88e5 Mon Sep 17 00:00:00 2001 From: Alex Collins Date: Thu, 25 Apr 2019 13:49:19 -0700 Subject: [PATCH 13/14] fix --- applications/templates/helm-guestbook.yaml | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 applications/templates/helm-guestbook.yaml diff --git a/applications/templates/helm-guestbook.yaml b/applications/templates/helm-guestbook.yaml new file mode 100644 index 0000000000..58b99f03b2 --- /dev/null +++ b/applications/templates/helm-guestbook.yaml @@ -0,0 +1,17 @@ +apiVersion: argoproj.io/v1alpha1 +kind: Application +metadata: + name: helm-guestbook + namespace: argocd +spec: + destination: + namespace: argocd + server: {{ .Values.spec.destination.server }} + project: default + source: + path: helm-guestbook + repoURL: https://github.com/argoproj/argocd-example-apps + targetRevision: {{ .Values.spec.source.targetRevision }} + syncPolicy: + automated: + prune: true From 997c52fd6f37c3feed9640bfbf9e7c2ef2a6f993 Mon Sep 17 00:00:00 2001 From: Alex Collins Date: Thu, 25 Apr 2019 13:49:56 -0700 Subject: [PATCH 14/14] fix --- applications/templates/kustomize-guestbook.yaml | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 applications/templates/kustomize-guestbook.yaml diff --git a/applications/templates/kustomize-guestbook.yaml b/applications/templates/kustomize-guestbook.yaml new file mode 100644 index 0000000000..9c52bc1a4e --- /dev/null +++ b/applications/templates/kustomize-guestbook.yaml @@ -0,0 +1,17 @@ +apiVersion: argoproj.io/v1alpha1 +kind: Application +metadata: + name: kustomize-guestbook + namespace: argocd +spec: + destination: + namespace: argocd + server: {{ .Values.spec.destination.server }} + project: default + source: + path: kustomize-guestbook + repoURL: https://github.com/argoproj/argocd-example-apps + targetRevision: {{ .Values.spec.source.targetRevision }} + syncPolicy: + automated: + prune: true