Add helm unittests (#380)

This commit is contained in:
Otto Bittner 2022-10-31 19:25:02 +01:00 committed by GitHub
parent 3933a97567
commit 30bdbd9b85
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
68 changed files with 1217 additions and 105 deletions

View file

@ -1,4 +1,4 @@
{{ if eq .Values.csp "AWS" }}
{{- if eq .Values.csp "AWS" -}}
apiVersion: apps/v1
kind: DaemonSet
metadata:
@ -60,4 +60,4 @@ spec:
hostPath:
path: /etc/pki
updateStrategy: {}
{{ end }}
{{- end -}}

View file

@ -1,4 +1,4 @@
{{ if eq .Values.csp "Azure" }}
{{- if eq .Values.csp "Azure" -}}
apiVersion: apps/v1
kind: DaemonSet
metadata:
@ -70,4 +70,4 @@ spec:
secret:
secretName: azureconfig
updateStrategy: {}
{{ end }}
{{- end -}}

View file

@ -1,4 +1,4 @@
{{ if eq .Values.csp "Azure" }}
{{- if eq .Values.csp "Azure" -}}
apiVersion: v1
kind: Secret
metadata:
@ -6,4 +6,4 @@ metadata:
namespace: {{ .Release.Namespace }}
data:
azure.json: {{ .Values.Azure.azureConfig | b64enc }}
{{ end }}
{{- end -}}

View file

@ -1,4 +1,4 @@
{{ if eq .Values.csp "GCP" }}
{{- if eq .Values.csp "GCP" -}}
apiVersion: v1
kind: ConfigMap
metadata:
@ -6,4 +6,4 @@ metadata:
namespace: {{ .Release.Namespace }}
data:
gce.conf: "[global]\nproject-id = {{.Values.GCP.projectID }}\nuse-metadata-server = true\nnode-tags = constellation-{{ .Values.GCP.uid }}\n"
{{ end }}
{{- end -}}

View file

@ -1,4 +1,4 @@
{{ if eq .Values.csp "GCP" }}
{{- if eq .Values.csp "GCP" -}}
apiVersion: apps/v1
kind: DaemonSet
metadata:
@ -81,4 +81,4 @@ spec:
secret:
secretName: gcekey
updateStrategy: {}
{{ end }}
{{- end -}}

View file

@ -1,4 +1,4 @@
{{ if eq .Values.csp "GCP" }}
{{- if eq .Values.csp "GCP" -}}
apiVersion: v1
kind: Secret
metadata:
@ -6,4 +6,4 @@ metadata:
namespace: {{ .Release.Namespace }}
data:
key.json: {{ .Values.GCP.secretData | b64enc }}
{{ end }}
{{- end -}}

View file

@ -10,7 +10,7 @@ data:
{{- if eq .Values.csp "Azure" }}
# ConfigMap.data is of type map[string]string. quote will not quote a quoted string.
enforceIdKeyDigest: {{ .Values.enforceIdKeyDigest | quote }}
idkeydigest: {{ .Values.idkeydigest }}
idkeydigest: {{ .Values.idkeydigest | quote }}
{{- end }}
binaryData:
measurementSalt: {{ .Values.measurementSalt }}

View file

@ -27,8 +27,7 @@
"image": {
"description": "Container image to use for the spawned pods.",
"type": "string",
"examples": ["ghcr.io/edgelesssys/constellation/join-service:latest"],
"pattern": "ghcr.io/edgelesssys/constellation/join-service:.+"
"examples": ["ghcr.io/edgelesssys/constellation/join-service:latest"]
},
"measurementSalt": {
"description": "Salt used to generate node measurements",

View file

@ -4,8 +4,7 @@
"image": {
"description": "Container image to use for the spawned pods.",
"type": "string",
"examples": ["ghcr.io/edgelesssys/constellation/kms:latest"],
"pattern": "ghcr.io/edgelesssys/constellation/kms:*"
"examples": ["ghcr.io/edgelesssys/constellation/kms:latest"]
},
"masterSecret": {
"description": "Secret used to derive key material within the cluster",