switch to applicationset pattern

This commit is contained in:
douzeb 2022-12-19 00:36:54 +01:00
parent 49158e6c05
commit 26f2be68b1
6 changed files with 11179 additions and 0 deletions

View file

@ -15,6 +15,21 @@ spec:
path: deploy/k8s-poc-demo/prod/ path: deploy/k8s-poc-demo/prod/
repoURL: https://git.distrilab.fr/douzeb/distrilab-app-of-apps.git repoURL: https://git.distrilab.fr/douzeb/distrilab-app-of-apps.git
targetRevision: HEAD targetRevision: HEAD
---
# Argo CD App definition for Argo CD itself
# apiVersion: argoproj.io/v1alpha1
# kind: Application
# metadata:
# name: argocd
# spec:
# destination:
# server: https://kubernetes.default.svc
# namespace: argocd
# project: default
# source:
# path: deploy/argocd/prod/
# repoURL: https://git.distrilab.fr/douzeb/distrilab-app-of-apps.git
# targetRevision: HEAD
# --- # ---
# # Argo CD App definition for another app # # Argo CD App definition for another app
# apiVersion: argoproj.io/v1alpha1 # apiVersion: argoproj.io/v1alpha1

View file

@ -0,0 +1,32 @@
---
apiVersion: v1
kind: Namespace
metadata:
name: infra
labels:
app: infra
---
apiVersion: argoproj.io/v1alpha1
kind: ApplicationSet
metadata:
name: infra-distrilab
spec:
generators:
- list:
elements:
- app: k8s-poc-demo
overlay: prod
# - app: argocd
# overlay: prod
template:
metadata:
name: '{{app}}-{{overlay}}'
spec:
project: default
source:
repoURL: https://git.distrilab.fr/douzeb/distrilab-app-of-apps.git
targetRevision: HEAD
path: deploy/{{app}}/{{overlay}}
destination:
server: https://kubernetes.default.svc
namespace: infra

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,7 @@
---
apiVersion: v1
kind: Namespace
metadata:
name: argocd
labels:
app: argocd

View file

@ -0,0 +1,3 @@
resources:
- argocd-namespace.yaml
- argocd-install.yaml

View file

@ -0,0 +1,3 @@
bases:
- ../base/
#namePrefix: prod-