Browse Source

Fix cloud_resolver type from str to list (issue #7605) (#7606)

pull/7621/head
Pavel Martynov 3 years ago
committed by GitHub
parent
commit
29c2fbdbc1
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 8 deletions
  1. 11
      roles/kubernetes/preinstall/tasks/0040-set_facts.yml

11
roles/kubernetes/preinstall/tasks/0040-set_facts.yml

@ -50,14 +50,9 @@
{% for d in [ 'default.svc.' + dns_domain, 'svc.' + dns_domain ] + searchdomains|default([]) -%} {% for d in [ 'default.svc.' + dns_domain, 'svc.' + dns_domain ] + searchdomains|default([]) -%}
{{ dns_domain }}.{{ d }}./{{ d }}.{{ d }}./com.{{ d }}./ {{ dns_domain }}.{{ d }}./{{ d }}.{{ d }}./com.{{ d }}./
{%- endfor %} {%- endfor %}
cloud_resolver: >-
{%- if cloud_provider is defined and cloud_provider == 'gce' -%}
['169.254.169.254']
{%- elif cloud_provider is defined and cloud_provider == 'aws' -%}
['169.254.169.253']
{%- else -%}
[]
{%- endif -%}
cloud_resolver: "{{ ['169.254.169.254'] if cloud_provider is defined and cloud_provider == 'gce' else
['169.254.169.253'] if cloud_provider is defined and cloud_provider == 'aws' else
[] }}"
- name: check if kubelet is configured - name: check if kubelet is configured
stat: stat:

Loading…
Cancel
Save