Skip to content

Commit

Permalink
S3 custom backend support (#98)
Browse files Browse the repository at this point in the history
  • Loading branch information
fraliv13 authored Nov 22, 2024
1 parent 0d39153 commit a46f5cf
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 1 deletion.
29 changes: 28 additions & 1 deletion helm/templates/provisioner-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,12 @@ spec:
app.kubernetes.io/version: {{ .Values.global.tag }}
app.kubernetes.io/managed-by: "helm"
spec:
{{- if .Values.global.s3.enabled }}
volumes:
- name: provisioner-secrets
secret:
secretName: provisioner-secrets
{{- end }}
containers:
- name: provisioning-controller
image: "{{ .Values.global.registry }}/platform-controllers:{{ .Values.global.tag }}"
Expand Down Expand Up @@ -85,11 +91,21 @@ spec:
name: azure-config
key: tenantId
{{- end }}
{{- if eq .Values.global.backend.type "cloud" }}
- name: PULUMI_ACCESS_TOKEN
valueFrom:
secretKeyRef:
name: provisioner-secrets
key: pulumiAccessToken
{{- else if eq .Values.global.backend.type "custom" }}
- name: PULUMI_BACKEND_URL
value: {{ .Values.global.backend.customBackedUrl | quote }}
- name: PULUMI_CONFIG_PASSPHRASE
valueFrom:
secretKeyRef:
name: provisioner-secrets
key: pulumiConfigPassphrase
{{- end }}
{{- if .Values.global.vault.enabled }}
- name: VAULT_ADDR
value: "{{ .Values.global.vault.address }}"
Expand All @@ -99,8 +115,19 @@ spec:
name: provisioner-secrets
key: vaultAccessToken
{{- end }}
{{- if .Values.global.s3.enabled }}
- name: AWS_PROFILE
value: "{{ .Values.global.s3.profile }}"
{{- end }}
- name: RUSI_ENABLED
value: "{{ .Values.global.rusi.enabled }}"
value: "{{ .Values.global.rusi.enabled }}"
{{- if .Values.global.s3.enabled }}
volumeMounts:
- mountPath: "/home/nonroot/.aws/credentials"
name: provisioner-secrets
subPath: s3Credentials
readOnly: true
{{- end }}
command:
- "/tenant-provisioner"
args:
Expand Down
7 changes: 7 additions & 0 deletions helm/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,11 @@ global:
enabled: true
azure:
enabled: true
backend:
type: cloud # cloud | custom
customBackedUrl: s3://my-bucket?region=ro&endpoint=http://my-minio-server:9000&disableSSL=true&s3ForcePathStyle=true
s3:
enabled: false
profile: minio


0 comments on commit a46f5cf

Please sign in to comment.