Enable Fedora to use dnf-automatic to install os patches
This commit is contained in:
		| @@ -28,6 +28,30 @@ | |||||||
|     autoclean: 'yes' |     autoclean: 'yes' | ||||||
|     autoremove: 'yes' |     autoremove: 'yes' | ||||||
|     upgrade: 'dist' |     upgrade: 'dist' | ||||||
|  | - name: 'Ensure dnf-automatic installation' | ||||||
|  |   when: | ||||||
|  |     - ansible_system == 'Linux' | ||||||
|  |     - ansible_distribution == 'Fedora' | ||||||
|  |     - ansible_distribution_major_version >= 21 | ||||||
|  |   package: | ||||||
|  |     name: | ||||||
|  |       - 'dnf-automatic' | ||||||
|  |     state: 'present' | ||||||
|  |   notify: | ||||||
|  |     - 'ensure_os_patch.package_facts' | ||||||
|  |     - 'ensure_os_patch.service_facts' | ||||||
|  | - name: 'Ensure dnf-automatic runs' | ||||||
|  |   when: | ||||||
|  |     - ansible_system == 'Linux' | ||||||
|  |     - ansible_distribution == 'Fedora' | ||||||
|  |     - ansible_distribution_major_version >= 21 | ||||||
|  |   service: | ||||||
|  |     enabled: 'yes' | ||||||
|  |     name: 'dnf-automatic-install.timer' | ||||||
|  |     state: 'running' | ||||||
|  |   notify: | ||||||
|  |     - 'ensure_os_patch.package_facts' | ||||||
|  |     - 'ensure_os_patch.service_facts' | ||||||
| - name: 'flush handlers' | - name: 'flush handlers' | ||||||
|   meta: 'flush_handlers' |   meta: 'flush_handlers' | ||||||
|  |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user