[home-assistant] allow setting a base64-encoded SSH private key (#429)

Co-authored-by: Bᴇʀɴᴅ Sᴄʜᴏʀɢᴇʀs <6213398+bjw-s@users.noreply.github.com>
This commit is contained in:
ᗪєνιη ᗷυнʟ 2020-12-23 09:47:01 -05:00 committed by GitHub
parent 33b54fc068
commit b290bcd0a1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 13 additions and 2 deletions

View File

@ -2,7 +2,7 @@ apiVersion: v2
appVersion: 2020.12.1 appVersion: 2020.12.1
description: Home Assistant description: Home Assistant
name: home-assistant name: home-assistant
version: 5.1.1 version: 5.2.0
keywords: keywords:
- home-assistant - home-assistant
- hass - hass

View File

@ -1,4 +1,4 @@
{{- if .Values.git.deployKey }} {{- if or .Values.git.deployKey .Values.git.deployKeyBase64 }}
apiVersion: v1 apiVersion: v1
kind: Secret kind: Secret
metadata: metadata:
@ -7,5 +7,9 @@ metadata:
{{- include "common.labels" . | nindent 4 }} {{- include "common.labels" . | nindent 4 }}
type: Opaque type: Opaque
data: data:
{{- if .Values.git.deployKey }}
id_rsa: {{ .Values.git.deployKey | b64enc | quote }} id_rsa: {{ .Values.git.deployKey | b64enc | quote }}
{{- else }}
id_rsa: {{ .Values.git.deployKeyBase64 | quote }}
{{- end }}
{{- end }} {{- end }}

View File

@ -18,12 +18,19 @@ service:
# # Enable devices to be discoverable # # Enable devices to be discoverable
# hostNetwork: true # hostNetwork: true
# # When hostNetwork is true set dnsPolicy to ClusterFirstWithHostNet
# dnsPolicy: ClusterFirstWithHostNet
# # Enable passing thru a USB device to Home Assistant # # Enable passing thru a USB device to Home Assistant
# securityContext: # securityContext:
# privileged: true # privileged: true
# Allow access a Git repository by passing in a private SSH key
git: git:
# Raw SSH private key
deployKey: "" deployKey: ""
# Base64-encoded SSH private key. When both variables are set, the raw SSH key takes precedence.
deployKeyBase64: ""
# Enable a prometheus-operator servicemonitor # Enable a prometheus-operator servicemonitor
prometheus: prometheus: