feat: convert many
This commit is contained in:
14
clusters/cl01tl/helm/home-assistant/templates/_helpers.tpl
Normal file
14
clusters/cl01tl/helm/home-assistant/templates/_helpers.tpl
Normal file
@@ -0,0 +1,14 @@
|
||||
{{/*
|
||||
Common labels
|
||||
*/}}
|
||||
{{- define "custom.labels" -}}
|
||||
{{ include "custom.selectorLabels" $ }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Selector labels
|
||||
*/}}
|
||||
{{- define "custom.selectorLabels" -}}
|
||||
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||
app.kubernetes.io/part-of: {{ .Release.Name }}
|
||||
{{- end }}
|
||||
@@ -1,42 +1,40 @@
|
||||
apiVersion: external-secrets.io/v1
|
||||
kind: ExternalSecret
|
||||
metadata:
|
||||
name: home-assistant-code-server-password-secret
|
||||
name: home-assistant-code-server-password
|
||||
namespace: {{ .Release.Namespace }}
|
||||
labels:
|
||||
app.kubernetes.io/name: home-assistant-code-server-password-secret
|
||||
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||
app.kubernetes.io/part-of: {{ .Release.Name }}
|
||||
app.kubernetes.io/name: home-assistant-code-server-password
|
||||
{{- include "custom.labels" . | nindent 4 }}
|
||||
spec:
|
||||
secretStoreRef:
|
||||
kind: ClusterSecretStore
|
||||
name: vault
|
||||
name: openbao
|
||||
data:
|
||||
- secretKey: PASSWORD
|
||||
remoteRef:
|
||||
key: /cl01tl/home-assistant/code-server/auth
|
||||
property: PASSWORD
|
||||
key: /cl01tl/home-assistant/code-server
|
||||
property: password
|
||||
- secretKey: SUDO_PASSWORD
|
||||
remoteRef:
|
||||
key: /cl01tl/home-assistant/code-server/auth
|
||||
property: SUDO_PASSWORD
|
||||
key: /cl01tl/home-assistant/code-server
|
||||
property: sudo-password
|
||||
|
||||
---
|
||||
apiVersion: external-secrets.io/v1
|
||||
kind: ExternalSecret
|
||||
metadata:
|
||||
name: home-assistant-token-secret
|
||||
name: home-assistant-metric-token
|
||||
namespace: {{ .Release.Namespace }}
|
||||
labels:
|
||||
app.kubernetes.io/name: home-assistant-token-secret
|
||||
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||
app.kubernetes.io/part-of: {{ .Release.Name }}
|
||||
app.kubernetes.io/name: home-assistant-metric-token
|
||||
{{- include "custom.labels" . | nindent 4 }}
|
||||
spec:
|
||||
secretStoreRef:
|
||||
kind: ClusterSecretStore
|
||||
name: vault
|
||||
name: openbao
|
||||
data:
|
||||
- secretKey: bearer-token
|
||||
remoteRef:
|
||||
key: /cl01tl/home-assistant/auth
|
||||
key: /cl01tl/home-assistant/config
|
||||
property: bearer-token
|
||||
|
||||
@@ -35,7 +35,7 @@ home-assistant:
|
||||
value: /config
|
||||
envFrom:
|
||||
- secretRef:
|
||||
name: home-assistant-code-server-password-secret
|
||||
name: home-assistant-code-server-password
|
||||
service:
|
||||
main:
|
||||
controller: main
|
||||
@@ -63,7 +63,7 @@ home-assistant:
|
||||
scrapeTimeout: 1m
|
||||
path: /api/prometheus
|
||||
bearerTokenSecret:
|
||||
name: home-assistant-token-secret
|
||||
name: home-assistant-metric-token
|
||||
key: bearer-token
|
||||
route:
|
||||
main:
|
||||
|
||||
Reference in New Issue
Block a user