argocd: mv all namespaces to a separate app

This commit is contained in:
Andrey Kartashov 2019-11-15 20:38:15 +07:00
parent cbd796ec91
commit 5bb0281478
8 changed files with 22 additions and 14 deletions

View file

@ -1,16 +1,17 @@
create namespaces
$ kubectl --context=gullfaxi apply -R apps/namespaces
install nginx-ingress
$ helm dep update apps/system/nginx-ingress
$ kubectl --context=gullfaxi create ns nginx-ingress
$ helm template --name nginx-ingress --namespace nginx-ingress apps/system/nginx-ingress | kubectl --context=gullfaxi --namespace nginx-ingress apply -f -
install cert-manager with cluster issuer
$ helm repo add jetstack https://charts.jetstack.io
$ helm dep update apps/system/cert-manager
$ kubectl --context=gullfaxi create ns cert-manager
$ helm template --name cert-manager --namespace cert-manager apps/system/cert-manager | kubectl --context=gullfaxi --namespace cert-manager apply -f -
install argocd

View file

@ -2,5 +2,3 @@ apiVersion: v1
kind: Namespace
metadata:
name: argocd
annotations:
argocd.argoproj.io/sync-wave: "-1"

View file

@ -2,5 +2,3 @@ apiVersion: v1
kind: Namespace
metadata:
name: cert-manager
annotations:
argocd.argoproj.io/sync-wave: "-1"

View file

@ -2,5 +2,3 @@ apiVersion: v1
kind: Namespace
metadata:
name: nginx-ingress
annotations:
argocd.argoproj.io/sync-wave: "-1"

View file

@ -2,5 +2,3 @@ apiVersion: v1
kind: Namespace
metadata:
name: oauth2-proxy
annotations:
argocd.argoproj.io/sync-wave: "-1"

View file

@ -2,5 +2,3 @@ apiVersion: v1
kind: Namespace
metadata:
name: prometheus-operator
annotations:
argocd.argoproj.io/sync-wave: "-1"

View file

@ -2,5 +2,3 @@ apiVersion: v1
kind: Namespace
metadata:
name: sealedsecrets
annotations:
argocd.argoproj.io/sync-wave: "-1"

View file

@ -0,0 +1,19 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: namespaces
namespace: argocd
finalizers:
- resources-finalizer.argocd.argoproj.io
spec:
destination:
namespace: default
server: https://kubernetes.default.svc
project: default
source:
path: apps/namespaces
repoURL: git@github.com:gorilych/gf-k8s
syncPolicy:
automated:
prune: true
selfHeal: true