Skip to content

Commit

Permalink
Add exoscale external dns values (#15837)
Browse files Browse the repository at this point in the history
Signed-off-by: Valentin Delaye <jonesbusy@gmail.com>
  • Loading branch information
jonesbusy authored Apr 3, 2023
1 parent f3294dc commit 8facec5
Show file tree
Hide file tree
Showing 6 changed files with 44 additions and 1 deletion.
2 changes: 1 addition & 1 deletion bitnami/external-dns/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,4 @@ sources:
- https://github.com/kubernetes-sigs/external-dns
- https://github.com/bitnami/containers/tree/main/bitnami/external-dns
- https://github.com/kubernetes-sigs/external-dns
version: 6.15.1
version: 6.16.0
3 changes: 3 additions & 0 deletions bitnami/external-dns/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,9 @@ The command removes all the Kubernetes components associated with the chart and
| `designate.customCA.content` | When using the Designate provider, set the content of the custom CA | `""` |
| `designate.customCA.mountPath` | When using the Designate provider, set the mountPath in which to mount the custom CA configuration | `/config/designate` |
| `designate.customCA.filename` | When using the Designate provider, set the custom CA configuration filename | `designate-ca.pem` |
| `exoscale.apiKey` | When using the Exoscale provider, `EXTERNAL_DNS_EXOSCALE_APIKEY` to set (optional) | `""` |
| `exoscale.apiToken` | When using the Exoscale provider, `EXTERNAL_DNS_EXOSCALE_APISECRET` to set (optional) | `""` |
| `exoscale.secretName` | Use an existing secret with keys "exoscale_api_key" and "exoscale_api_token" defined. | `""` |
| `digitalocean.apiToken` | When using the DigitalOcean provider, `DO_TOKEN` to set (optional) | `""` |
| `digitalocean.secretName` | Use an existing secret with key "digitalocean_api_token" defined. | `""` |
| `google.project` | When using the Google provider, specify the Google project (required when provider=google) | `""` |
Expand Down
4 changes: 4 additions & 0 deletions bitnami/external-dns/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,8 @@ Return true if a secret object should be created
{{- true -}}
{{- else if and (eq .Values.provider "digitalocean") .Values.digitalocean.apiToken (not .Values.digitalocean.secretName) -}}
{{- true -}}
{{- else if and (eq .Values.provider "exoscale") .Values.exoscale.apiKey (not .Values.exoscale.secretName) -}}
{{- true -}}
{{- else if and (eq .Values.provider "google") .Values.google.serviceAccountKey (not .Values.google.serviceAccountSecret) -}}
{{- true -}}
{{- else if and (eq .Values.provider "hetzner") .Values.hetzner.token (not .Values.hetzner.secretName) -}}
Expand Down Expand Up @@ -170,6 +172,8 @@ Return the name of the Secret used to store the passwords
{{- .Values.cloudflare.secretName }}
{{- else if and (eq .Values.provider "digitalocean") .Values.digitalocean.secretName }}
{{- .Values.digitalocean.secretName }}
{{- else if and (eq .Values.provider "exoscale") .Values.exoscale.secretName }}
{{- .Values.exoscale.secretName }}
{{- else if and (eq .Values.provider "google") .Values.google.serviceAccountSecret }}
{{- .Values.google.serviceAccountSecret }}
{{- else if and (eq .Values.provider "hetzner") .Values.hetzner.secretName }}
Expand Down
17 changes: 17 additions & 0 deletions bitnami/external-dns/templates/dep-ds.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -444,6 +444,23 @@ spec:
name: {{ template "external-dns.secretName" . }}
key: digitalocean_api_token
{{- end }}
{{- if (eq .Values.provider "exoscale") }}
# Exoscale environment variables
{{- if (or .Values.exoscale.apiKey .Values.exoscale.secretName) }}
- name: EXTERNAL_DNS_EXOSCALE_APIKEY
valueFrom:
secretKeyRef:
name: {{ template "external-dns.secretName" . }}
key: exoscale_api_key
{{- end }}
{{- if (or .Values.exoscale.apiToken .Values.exoscale.secretName) }}
- name: EXTERNAL_DNS_EXOSCALE_APISECRET
valueFrom:
secretKeyRef:
name: {{ template "external-dns.secretName" . }}
key: exoscale_api_token
{{- end }}
{{- end }}
{{- if eq .Values.provider "google" }}
# Google environment variables
{{- if or .Values.google.serviceAccountSecret .Values.google.serviceAccountKey }}
Expand Down
4 changes: 4 additions & 0 deletions bitnami/external-dns/templates/secret.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,10 @@ data:
{{- if eq .Values.provider "digitalocean" }}
digitalocean_api_token: {{ .Values.digitalocean.apiToken | b64enc | quote }}
{{- end }}
{{- if eq .Values.provider "exoscale" }}
exoscale_api_key: {{ .Values.exoscale.apiKey | b64enc | quote }}
exoscale_api_token: {{ .Values.exoscale.apiToken | b64enc | quote }}
{{- end }}
{{- if eq .Values.provider "infoblox" }}
infoblox_wapi_username: {{ .Values.infoblox.wapiUsername | b64enc | quote }}
infoblox_wapi_password: {{ .Values.infoblox.wapiPassword | b64enc | quote }}
Expand Down
15 changes: 15 additions & 0 deletions bitnami/external-dns/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -382,6 +382,21 @@ designate:
content: ""
mountPath: "/config/designate"
filename: "designate-ca.pem"
## Exoscale configuration to be set via arguments/env. variables
##
exoscale:
## @param exoscale.apiKey When using the Exoscale provider, `EXTERNAL_DNS_EXOSCALE_APIKEY` to set (optional)
##
apiKey: ""
## @param exoscale.apiToken When using the Exoscale provider, `EXTERNAL_DNS_EXOSCALE_APISECRET` to set (optional)
##
apiToken: ""
## @param exoscale.secretName Use an existing secret with keys "exoscale_api_key" and "exoscale_api_token" defined.
## This ignores exoscale.apiKey and exoscale.apiToken
##
secretName: ""
## Google configuration to be set via arguments/env. variables
##
## DigitalOcean configuration to be set via arguments/env. variables
##
digitalocean:
Expand Down

0 comments on commit 8facec5

Please sign in to comment.