Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 31 additions & 0 deletions app-of-apps/my-app-list/argo-workflows.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: argo-workflows
# You'll usually want to add your resources to the argocd namespace.
namespace: argocd
# Add a this finalizer ONLY if you want these to cascade delete.
finalizers:
- resources-finalizer.argocd.argoproj.io
spec:
# The project the application belongs to.
project: default

# Source of the application manifests
source:
repoURL: https://github.com/codefresh-contrib/gitops-cert-level-2-examples.git
targetRevision: HEAD
path: ./app-of-apps/manifests

# Destination cluster and namespace to deploy the application
destination:
server: https://kubernetes.default.svc
namespace: argo-workflows

# Sync policy
syncPolicy:
syncOptions:
- CreateNamespace=true
automated: # automated sync by default retries failed attempts 5 times with following delays between attempts ( 5s, 10s, 20s, 40s, 80s ); retry controlled using `retry` field.
prune: true # Specifies if resources should be pruned during auto-syncing ( false by default ).
selfHeal: true # Specifies if partial app sync should be executed when resources are changed only in target Kubernetes cluster and no git change detected ( false by default ).
31 changes: 31 additions & 0 deletions app-of-apps/my-app-list/kubeview.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: kubeview
# You'll usually want to add your resources to the argocd namespace.
namespace: argocd
# Add a this finalizer ONLY if you want these to cascade delete.
finalizers:
- resources-finalizer.argocd.argoproj.io
spec:
# The project the application belongs to.
project: default

# Source of the application manifests
source:
repoURL: https://github.com/codefresh-contrib/gitops-cert-level-2-examples.git
targetRevision: HEAD
path: ./app-of-apps/manifests

# Destination cluster and namespace to deploy the application
destination:
server: https://kubernetes.default.svc
namespace: kubeview

# Sync policy
syncPolicy:
syncOptions:
- CreateNamespace=true
automated: # automated sync by default retries failed attempts 5 times with following delays between attempts ( 5s, 10s, 20s, 40s, 80s ); retry controlled using `retry` field.
prune: true # Specifies if resources should be pruned during auto-syncing ( false by default ).
selfHeal: true # Specifies if partial app sync should be executed when resources are changed only in target Kubernetes cluster and no git change detected ( false by default ).
3 changes: 1 addition & 2 deletions app-of-apps/root-app/my-application.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ spec:

# Source of the application manifests
source:
repoURL: https://github.com/codefresh-contrib/gitops-cert-level-2-examples.git
repoURL: https://github.com/mattwilsn/gitops-cert-level-2-examples.git
targetRevision: HEAD
path: ./app-of-apps/my-app-list

Expand All @@ -31,4 +31,3 @@ spec:
prune: true # Specifies if resources should be pruned during auto-syncing ( false by default ).
selfHeal: true # Specifies if partial app sync should be executed when resources are changed only in target Kubernetes cluster and no git change detected ( false by default ).
allowEmpty: false # Allows deleting all application resources during automatic syncing ( false by default ).

38 changes: 38 additions & 0 deletions application-sets/my-application-sets/many-apps.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
apiVersion: argoproj.io/v1alpha1
kind: ApplicationSet
metadata:
name: many-apps-application-set
namespace: argocd
spec:
generators:
- git:
repoURL: https://github.com/codefresh-contrib/gitops-cert-level-2-examples.git
revision: HEAD
directories:
- path: application-sets/example-apps/*
template:
metadata:
name: '{{path.basename}}'
spec:
# The project the application belongs to.
project: default

# Source of the application manifests
source:
repoURL: https://github.com/codefresh-contrib/gitops-cert-level-2-examples.git
targetRevision: HEAD
path: '{{path}}'

# Destination cluster and namespace to deploy the application
destination:
server: https://kubernetes.default.svc
namespace: '{{path.basename}}'

# Sync policy
syncPolicy:
syncOptions:
- CreateNamespace=true
automated: # automated sync by default retries failed attempts 5 times with following delays between attempts ( 5s, 10s, 20s, 40s, 80s ); retry controlled using `retry` field.
prune: true # Specifies if resources should be pruned during auto-syncing ( false by default ).
selfHeal: true # Specifies if partial app sync should be executed when resources are changed only in target Kubernetes cluster and no git change detected ( false by default ).

Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
apiVersion: argoproj.io/v1alpha1
kind: ApplicationSet
metadata:
name: multi-cluster-application-set
namespace: argocd
spec:
generators:
- clusters: {} # Automatically use all clusters defined within Argo CD
template:
metadata:
name: '{{name}}-billing-app'
spec:
# The project the application belongs to.
project: default

# Source of the application manifests
source:
repoURL: https://github.com/codefresh-contrib/gitops-cert-level-2-examples.git
targetRevision: HEAD
path: ./application-sets/manifests

# Destination cluster and namespace to deploy the application
destination:
server: '{{server}}'
namespace: billing

# Sync policy
syncPolicy:
syncOptions:
- CreateNamespace=true
automated: # automated sync by default retries failed attempts 5 times with following delays between attempts ( 5s, 10s, 20s, 40s, 80s ); retry controlled using `retry` field.
prune: true # Specifies if resources should be pruned during auto-syncing ( false by default ).
selfHeal: true # Specifies if partial app sync should be executed when resources are changed only in target Kubernetes cluster and no git change detected ( false by default ).

4 changes: 2 additions & 2 deletions environment-promotion/envs/prod/settings.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,12 @@ spec:
- name: webserver-simple
env:
- name: UI_THEME
value: "dark"
value: "light"
- name: CACHE_SIZE
value: "1024kb"
- name: PAGE_LIMIT
value: "25"
- name: SORTING
value: "ascending"
- name: N_BUCKETS
value: "12"
value: "24"
2 changes: 1 addition & 1 deletion environment-promotion/envs/prod/version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ spec:
spec:
containers:
- name: webserver-simple
image: docker.io/kostiscodefresh/simple-env-app:1.0
image: docker.io/kostiscodefresh/simple-env-app:3.0
2 changes: 1 addition & 1 deletion environment-promotion/envs/staging/version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ spec:
spec:
containers:
- name: webserver-simple
image: docker.io/kostiscodefresh/simple-env-app:2.0
image: docker.io/kostiscodefresh/simple-env-app:3.0
8 changes: 3 additions & 5 deletions image-updater/applications/always-latest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,20 @@ metadata:
name: always-latest01
namespace: argocd
annotations:
argocd-image-updater.argoproj.io/image-list: example=ghcr.io/codefresh-contrib/gitops-cert-level-2-examples
argocd-image-updater.argoproj.io/image-list: example=ghcr.io/mattwilsn/gitops-cert-level-2-examples
argocd-image-updater.argoproj.io/example.update-strategy: latest
spec:
project: default

source:
repoURL: https://github.com/codefresh-contrib/gitops-cert-level-2-examples.git
repoURL: https://github.com/mattwilsn/gitops-cert-level-2-examples.git
targetRevision: HEAD
path: ./image-updater/example-app/envs/qa/

destination:
server: https://kubernetes.default.svc
namespace: qa

# Sync policy
syncPolicy:
syncOptions:
- CreateNamespace=true

- CreateNamespace=true
9 changes: 3 additions & 6 deletions image-updater/applications/semver.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,18 @@ metadata:
name: follow-semver02
namespace: argocd
annotations:
argocd-image-updater.argoproj.io/image-list: ghcr.io/codefresh-contrib/gitops-cert-level-2-examples:~1
argocd-image-updater.argoproj.io/image-list: ghcr.io/mattwilsn/gitops-cert-level-2-examples:~1
spec:
project: default

source:
repoURL: https://github.com/codefresh-contrib/gitops-cert-level-2-examples.git
repoURL: https://github.com/mattwilsn/gitops-cert-level-2-examples.git
targetRevision: HEAD
path: ./image-updater/example-app/envs/staging/

destination:
server: https://kubernetes.default.svc
namespace: staging

# Sync policy
syncPolicy:
syncOptions:
- CreateNamespace=true

- CreateNamespace=true
4 changes: 2 additions & 2 deletions image-updater/example-app/envs/qa/version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ spec:
template:
spec:
containers:
- name: webserver-simple
image: ghcr.io/codefresh-contrib/gitops-cert-level-2-examples:1.0
- name: webserver-simple
image: ghcr.io/mattwilsn/gitops-cert-level-2-examples:1.0
4 changes: 2 additions & 2 deletions image-updater/example-app/envs/staging/version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ spec:
template:
spec:
containers:
- name: webserver-simple
image: ghcr.io/codefresh-contrib/gitops-cert-level-2-examples:1.0
- name: webserver-simple
image: ghcr.io/mattwilsn/gitops-cert-level-2-examples:1.0