Reload kubelet unit file if config is changed.

This commit is contained in:
Jeff Geerling 2018-05-31 18:54:55 -05:00
parent c287258b04
commit 9379018d86

View File

@ -22,7 +22,14 @@
regexp: 'Environment="KUBELET_EXTRA_ARGS=' regexp: 'Environment="KUBELET_EXTRA_ARGS='
insertafter: '^Environment=' insertafter: '^Environment='
state: present state: present
notify: restart kubelet register: kubelet_unit_file
- name: Reload systemd unit if args were changed.
systemd:
state: restarted
daemon_reload: yes
name: kubelet
when: kubelet_unit_file is changed
- name: Ensure kubelet is started and enabled at boot. - name: Ensure kubelet is started and enabled at boot.
service: service: