From: Alex Nordlund Date: Thu, 25 Aug 2022 02:39:11 +0000 (+0200) Subject: Allow S3 to use an existing secret (#18997) X-Git-Url: https://git.xn--scling-oua.cat.family/?a=commitdiff_plain;h=a9ff98e1dc8838cb91a2529efd24accd15d7ec41;p=mastodon.git Allow S3 to use an existing secret (#18997) --- diff --git a/chart/templates/deployment-web.yaml b/chart/templates/deployment-web.yaml index 8b8bb4f29..e57d1f6e1 100644 --- a/chart/templates/deployment-web.yaml +++ b/chart/templates/deployment-web.yaml @@ -74,6 +74,18 @@ spec: key: redis-password - name: "PORT" value: {{ .Values.mastodon.web.port | quote }} + {{- if (and .Values.mastodon.s3.enabled .Values.mastodon.s3.existingSecret) }} + - name: "AWS_SECRET_ACCESS_KEY" + valueFrom: + secretKeyRef: + name: {{ .Values.mastodon.s3.existingSecret }} + key: AWS_SECRET_ACCESS_KEY + - name: "AWS_ACCESS_KEY_ID" + valueFrom: + secretKeyRef: + name: {{ .Values.mastodon.s3.existingSecret }} + key: AWS_ACCESS_KEY_ID + {{- end -}} {{- if (not .Values.mastodon.s3.enabled) }} volumeMounts: - name: assets