Merge pull request #1315 from rsmitty/hostnames-upgrade

Resolve upgrade issues
This commit is contained in:
Spencer Smith 2017-05-30 11:40:19 -04:00 committed by GitHub
commit 2979faedc7
3 changed files with 3 additions and 4 deletions

View file

@ -1,6 +1,6 @@
--- ---
- name: Uncordon node - name: Uncordon node
command: "{{ bin_dir }}/kubectl uncordon {{ ansible_hostname }}" command: "{{ bin_dir }}/kubectl uncordon {{ inventory_hostname }}"
delegate_to: "{{ groups['kube-master'][0] }}" delegate_to: "{{ groups['kube-master'][0] }}"
when: needs_cordoning|default(false) when: needs_cordoning|default(false)

View file

@ -14,7 +14,7 @@
{% endif %} {% endif %}
- name: Cordon node - name: Cordon node
command: "{{ bin_dir }}/kubectl cordon {{ ansible_hostname }}" command: "{{ bin_dir }}/kubectl cordon {{ inventory_hostname }}"
delegate_to: "{{ groups['kube-master'][0] }}" delegate_to: "{{ groups['kube-master'][0] }}"
when: needs_cordoning when: needs_cordoning
@ -25,6 +25,6 @@
--ignore-daemonsets --ignore-daemonsets
--grace-period {{ drain_grace_period }} --grace-period {{ drain_grace_period }}
--timeout {{ drain_timeout }} --timeout {{ drain_timeout }}
--delete-local-data {{ ansible_hostname }} --delete-local-data {{ inventory_hostname }}
delegate_to: "{{ groups['kube-master'][0] }}" delegate_to: "{{ groups['kube-master'][0] }}"
when: needs_cordoning when: needs_cordoning

View file

@ -67,7 +67,6 @@
- { role: kubernetes/node, tags: node } - { role: kubernetes/node, tags: node }
- { role: kubernetes/master, tags: master } - { role: kubernetes/master, tags: master }
- { role: network_plugin, tags: network } - { role: network_plugin, tags: network }
- { role: upgrade/post-upgrade, tags: post-upgrade }
#Finally handle worker upgrades, based on given batch size #Finally handle worker upgrades, based on given batch size
- hosts: kube-node:!kube-master - hosts: kube-node:!kube-master