add support for using ansible 2.10.x for deploying kubespray (#7600)
* add support for using ansible 2.10.x for deploying kubespray * move dns-autoscaler-clusterrole{binding}.yml to files/ folder * note that ansible 2.10 is now experimentally supported * coredns: move files to templates like before #4341pull/7621/head
parent
e0c74fa082
commit
e9870b8d25
|
@ -162,7 +162,7 @@ Note: Upstart/SysV init based OS types are not supported.
|
||||||
## Requirements
|
## Requirements
|
||||||
|
|
||||||
- **Minimum required version of Kubernetes is v1.19**
|
- **Minimum required version of Kubernetes is v1.19**
|
||||||
- **Ansible v2.9.x, Jinja 2.11+ and python-netaddr is installed on the machine that will run Ansible commands, Ansible 2.10.x is not supported for now**
|
- **Ansible v2.9.x, Jinja 2.11+ and python-netaddr is installed on the machine that will run Ansible commands, Ansible 2.10.x is experimentally supported for now**
|
||||||
- The target servers must have **access to the Internet** in order to pull docker images. Otherwise, additional configuration is required (See [Offline Environment](docs/offline-environment.md))
|
- The target servers must have **access to the Internet** in order to pull docker images. Otherwise, additional configuration is required (See [Offline Environment](docs/offline-environment.md))
|
||||||
- The target servers are configured to allow **IPv4 forwarding**.
|
- The target servers are configured to allow **IPv4 forwarding**.
|
||||||
- If using IPv6 for pods and services, the target servers are configured to allow **IPv6 forwarding**.
|
- If using IPv6 for pods and services, the target servers are configured to allow **IPv6 forwarding**.
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
become: no
|
become: no
|
||||||
vars:
|
vars:
|
||||||
minimal_ansible_version: 2.9.0
|
minimal_ansible_version: 2.9.0
|
||||||
maximal_ansible_version: 2.10.0
|
maximal_ansible_version: 2.11.0
|
||||||
ansible_connection: local
|
ansible_connection: local
|
||||||
tasks:
|
tasks:
|
||||||
- name: "Check {{ minimal_ansible_version }} <= Ansible version < {{ maximal_ansible_version }}"
|
- name: "Check {{ minimal_ansible_version }} <= Ansible version < {{ maximal_ansible_version }}"
|
||||||
|
|
|
@ -1,20 +1,19 @@
|
||||||
---
|
---
|
||||||
- name: Kubernetes Apps | Lay Down CoreDNS Template
|
- name: Kubernetes Apps | Lay Down CoreDNS templates
|
||||||
action: "{{ item.module }}"
|
template:
|
||||||
args:
|
src: "{{ item.file }}.j2"
|
||||||
src: "{{ item.file }}{% if item.module == 'template' %}.j2{% endif %}"
|
|
||||||
dest: "{{ kube_config_dir }}/{{ item.file }}"
|
dest: "{{ kube_config_dir }}/{{ item.file }}"
|
||||||
with_items:
|
loop:
|
||||||
- { name: coredns, module: template, file: coredns-config.yml, type: configmap }
|
- { name: coredns, file: coredns-clusterrole.yml, type: clusterrole }
|
||||||
- { name: coredns, module: copy, file: coredns-sa.yml, type: sa }
|
- { name: coredns, file: coredns-clusterrolebinding.yml, type: clusterrolebinding }
|
||||||
- { name: coredns, module: template, file: coredns-deployment.yml, type: deployment }
|
- { name: coredns, file: coredns-config.yml, type: configmap }
|
||||||
- { name: coredns, module: template, file: coredns-svc.yml, type: svc }
|
- { name: coredns, file: coredns-deployment.yml, type: deployment }
|
||||||
- { name: coredns, module: copy, file: coredns-clusterrole.yml, type: clusterrole }
|
- { name: coredns, file: coredns-sa.yml, type: sa }
|
||||||
- { name: coredns, module: copy, file: coredns-clusterrolebinding.yml, type: clusterrolebinding }
|
- { name: coredns, file: coredns-svc.yml, type: svc }
|
||||||
- { name: dns-autoscaler, module: copy, file: dns-autoscaler-sa.yml, type: sa }
|
- { name: dns-autoscaler, file: dns-autoscaler.yml, type: deployment }
|
||||||
- { name: dns-autoscaler, module: copy, file: dns-autoscaler-clusterrole.yml, type: clusterrole }
|
- { name: dns-autoscaler, file: dns-autoscaler-clusterrole.yml, type: clusterrole }
|
||||||
- { name: dns-autoscaler, module: copy, file: dns-autoscaler-clusterrolebinding.yml, type: clusterrolebinding }
|
- { name: dns-autoscaler, file: dns-autoscaler-clusterrolebinding.yml, type: clusterrolebinding }
|
||||||
- { name: dns-autoscaler, module: template, file: dns-autoscaler.yml, type: deployment }
|
- { name: dns-autoscaler, file: dns-autoscaler-sa.yml, type: sa }
|
||||||
register: coredns_manifests
|
register: coredns_manifests
|
||||||
vars:
|
vars:
|
||||||
clusterIP: "{{ skydns_server }}"
|
clusterIP: "{{ skydns_server }}"
|
||||||
|
|
Loading…
Reference in New Issue