Fix api keys secret generation
Some checks failed
continuous-integration/drone/push Build is failing
Some checks failed
continuous-integration/drone/push Build is failing
This commit is contained in:
parent
7bd2605c1f
commit
514cd5a1da
2 changed files with 16 additions and 8 deletions
|
|
@ -1,14 +1,19 @@
|
|||
{% for i in item.solvers %}
|
||||
{% if i.solver == "dns01" %}
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: "{{ item.dns_provider }}-api-key"
|
||||
name: "{{ i.dns_provider }}-api-key"
|
||||
type: Opaque
|
||||
data:
|
||||
{% if item.dns_provider == "cloudflare" %}
|
||||
api-key: "{{ item.cloudflare_api_key | b64encode }}"
|
||||
{% elif item.dns_provider == "route53" %}
|
||||
{% if i.dns_provider == "cloudflare" %}
|
||||
api-key: "{{ i.cloudflare_api_key | b64encode }}"
|
||||
{% elif i.dns_provider == "route53" %}
|
||||
secret-access-key: "{{ lookup('hashi_vault', 'secret=clusters/route53:secret-access-key') | b64encode }}"
|
||||
{% elif item.dns_provider == "ovh" %}
|
||||
applicationSecret: "{{ item.applicationSecret | b64encode }}"
|
||||
{% elif i.dns_provider == "ovh" %}
|
||||
applicationSecret: "{{ i.applicationSecret | b64encode }}"
|
||||
{% endif %}
|
||||
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue