rancher-partner-charts/charts/kubecost/cost-analyzer/2.0.2/templates/aws-service-key-secret.yaml

21 lines
610 B
YAML

{{- if .Values.kubecostProductConfigs }}
{{- if .Values.kubecostProductConfigs.createServiceKeySecret }}
{{- if .Values.kubecostProductConfigs.awsServiceKeyName }}
apiVersion: v1
kind: Secret
metadata:
name: cloud-service-key
namespace: {{ .Release.Namespace }}
labels:
{{ include "cost-analyzer.commonLabels" . | nindent 4 }}
type: Opaque
stringData:
service-key.json: |-
{
"aws_access_key_id": "{{ .Values.kubecostProductConfigs.awsServiceKeyName }}",
"aws_secret_access_key": "{{ .Values.kubecostProductConfigs.awsServiceKeyPassword }}"
}
{{- end -}}
{{- end -}}
{{- end -}}