Skip to content

Commit

Permalink
[ha] moved home-assistant related resources to a single kustomization
Browse files Browse the repository at this point in the history
  • Loading branch information
gruberdev committed Jan 26, 2024
1 parent d7e7e59 commit 024857c
Show file tree
Hide file tree
Showing 7 changed files with 160 additions and 8 deletions.
37 changes: 37 additions & 0 deletions apps/argocd/base/core/home.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: home
namespace: argocd
labels:
app.kubernetes.io/category: home
spec:
project: apps
source:
repoURL: "https://github.com/gruberdev/homelab.git"
path: apps/argocd/base/home
targetRevision: main
destination:
namespace: homeassistant
name: in-cluster
syncPolicy:
automated:
prune: true
selfHeal: true
allowEmpty: false
managedNamespaceMetadata:
labels:
prometheus: enabled
syncOptions:
- Validate=false
- CreateNamespace=true
- ServerSideApply=true
- PrunePropagationPolicy=foreground
- PruneLast=true
- ApplyOutOfSyncOnly=false
retry:
limit: 10
backoff:
duration: 20s
factor: 2
maxDuration: 15m
15 changes: 9 additions & 6 deletions apps/argocd/base/apps/ha.yaml → apps/argocd/base/home/ha.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,12 @@ apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: homeassistant
labels:
app.kubernetes.io/category: home
spec:
project: apps
source:
repoURL: 'https://github.com/gruberdev/homelab.git'
repoURL: "https://github.com/gruberdev/homelab.git"
path: apps/home/ha
targetRevision: main
destination:
Expand All @@ -17,11 +19,12 @@ spec:
selfHeal: true
allowEmpty: true
syncOptions:
- Validate=false
- CreateNamespace=false
- PrunePropagationPolicy=foreground
- ApplyOutOfSyncOnly=false
- Prune=true
- Validate=false
- CreateNamespace=false
- PrunePropagationPolicy=foreground
- ApplyOutOfSyncOnly=false
- Prune=true
- ServerSideApply=true
retry:
limit: 5
backoff:
Expand Down
8 changes: 8 additions & 0 deletions apps/argocd/base/home/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- ha.yaml
- openwakeword.yaml
- piper.yaml
- whisper.yaml
- wyze.yaml
35 changes: 35 additions & 0 deletions apps/argocd/base/home/piper.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: piper
labels:
app.kubernetes.io/category: home
finalizers:
- resources-finalizer.argocd.argoproj.io
spec:
project: apps
source:
repoURL: "https://github.com/gruberdev/homelab.git"
path: apps/home/piper
targetRevision: main
destination:
namespace: homeassistant
name: in-cluster
syncPolicy:
automated:
prune: true
selfHeal: true
allowEmpty: true
syncOptions:
- Validate=false
- CreateNamespace=false
- PrunePropagationPolicy=foreground
- ApplyOutOfSyncOnly=false
- Prune=true
- ServerSideApply=true
retry:
limit: 5
backoff:
duration: 20s
factor: 2
maxDuration: 15m
35 changes: 35 additions & 0 deletions apps/argocd/base/home/whisper.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: whisper
labels:
app.kubernetes.io/category: home
finalizers:
- resources-finalizer.argocd.argoproj.io
spec:
project: apps
source:
repoURL: "https://github.com/gruberdev/homelab.git"
path: apps/home/whisper
targetRevision: main
destination:
namespace: homeassistant
name: in-cluster
syncPolicy:
automated:
prune: true
selfHeal: true
allowEmpty: true
syncOptions:
- Validate=false
- CreateNamespace=false
- PrunePropagationPolicy=foreground
- ApplyOutOfSyncOnly=false
- Prune=true
- ServerSideApply=true
retry:
limit: 5
backoff:
duration: 20s
factor: 2
maxDuration: 15m
35 changes: 35 additions & 0 deletions apps/argocd/base/home/wyze.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: wyze
labels:
app.kubernetes.io/category: home
finalizers:
- resources-finalizer.argocd.argoproj.io
spec:
project: apps
source:
repoURL: "https://github.com/gruberdev/homelab.git"
path: apps/home/wyze
targetRevision: main
destination:
namespace: homeassistant
name: in-cluster
syncPolicy:
automated:
prune: true
selfHeal: true
allowEmpty: true
syncOptions:
- Validate=false
- CreateNamespace=false
- PrunePropagationPolicy=foreground
- ApplyOutOfSyncOnly=false
- Prune=true
- ServerSideApply=true
retry:
limit: 5
backoff:
duration: 20s
factor: 2
maxDuration: 15m
3 changes: 1 addition & 2 deletions apps/argocd/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ resources:
# Core apps
- base/core/argocd.yaml
- base/core/data.yaml
- base/core/home.yaml
- base/core/nvidia.yaml
- base/core/nvidia-extra.yaml
- base/core/networking.yaml
Expand All @@ -22,9 +23,7 @@ resources:

# Applications
- base/apps/vault.yaml
- base/apps/ha.yaml
- base/apps/unifi.yaml
- base/apps/wyze.yaml

# Monitoring
- base/monitoring/kuma.yaml
Expand Down

0 comments on commit 024857c

Please sign in to comment.