summaryrefslogtreecommitdiffstats
path: root/roles/dnf-automatic/tasks
diff options
context:
space:
mode:
authorKevin Fenzi <kevin@scrye.com>2015-12-08 18:38:40 +0000
committerKevin Fenzi <kevin@scrye.com>2015-12-08 18:38:40 +0000
commitdc6f14bd314a3dfba8eb3b5c571decca40b1b4ed (patch)
tree3efbf8b56b5aa6824746b9fe82882b86c4495489 /roles/dnf-automatic/tasks
parentca6d1ac0128ea1e08c5ea01d0dfac4cd42ae6d6d (diff)
downloadansible-dc6f14bd314a3dfba8eb3b5c571decca40b1b4ed.tar.gz
ansible-dc6f14bd314a3dfba8eb3b5c571decca40b1b4ed.tar.xz
ansible-dc6f14bd314a3dfba8eb3b5c571decca40b1b4ed.zip
Create a dnf-automatic role, and switch taskotron/resultsdb dev to use it.
Diffstat (limited to 'roles/dnf-automatic/tasks')
-rw-r--r--roles/dnf-automatic/tasks/main.yml25
1 files changed, 25 insertions, 0 deletions
diff --git a/roles/dnf-automatic/tasks/main.yml b/roles/dnf-automatic/tasks/main.yml
new file mode 100644
index 000000000..13ff9f5dc
--- /dev/null
+++ b/roles/dnf-automatic/tasks/main.yml
@@ -0,0 +1,25 @@
+---
+
+#
+# This role adds dnf automatic package and configuration.
+# We want this on any public facing Fedora installs so we
+# can pick up security updates.
+#
+
+- name: install dnf-automatic
+ yum: name=dnf-automatic state=present
+ tags:
+ - packages
+ when: ansible_distribution == 'Fedora'
+
+- name: install /etc/dnf/automatic.conf
+ template: src=automatic.conf.j2 dest=/etc/dnf/automatic.conf mode=0644
+ tags:
+ - config
+ when: ansible_distribution == 'Fedora'
+
+- name: enable and start dnf-automatic
+ command: systemctl enable dnf-automatic.timer --now creates=/etc/systemd/system/basic.target.wants/dnf-automatic.timer
+ tags:
+ - config
+ when: ansible_distribution == 'Fedora'