summaryrefslogtreecommitdiffstats
path: root/roles/common/tasks
diff options
context:
space:
mode:
Diffstat (limited to 'roles/common/tasks')
-rw-r--r--roles/common/tasks/apt.yml36
-rw-r--r--roles/common/tasks/main.yml1
2 files changed, 37 insertions, 0 deletions
diff --git a/roles/common/tasks/apt.yml b/roles/common/tasks/apt.yml
new file mode 100644
index 0000000..9b553b0
--- /dev/null
+++ b/roles/common/tasks/apt.yml
@@ -0,0 +1,36 @@
+- name: Install various APT tools
+ apt: pkg={{ item }}
+ with_items:
+ - apt
+ - apt-listbugs
+ - apt-listchanges
+ - apt-show-versions
+ - debian-archive-keyring
+ - debian-goodies
+ - unattended-upgrades
+ - debfoster
+ - deborphan
+ - debsecan
+ - debsums
+ - update-notifier-common
+
+- name: Configure APT (1)
+ template: src=etc/apt/{{ item }}.j2
+ dest=/etc/apt/{{ item }}
+ owner=root group=root
+ mode=0644
+ with_items:
+ - sources.list
+ - preferences
+ notify:
+ - apt-get update
+
+- name: Configure APT (2)
+ copy: src=etc/apt/{{ item }}
+ dest=/etc/apt/{{ item }}
+ owner=root group=root
+ mode=0644
+ with_items:
+ - listchanges.conf
+ - apt.conf.d/10periodic
+ - apt.conf.d/50unattended-upgrades
diff --git a/roles/common/tasks/main.yml b/roles/common/tasks/main.yml
index 1abcbb6..d6a4266 100644
--- a/roles/common/tasks/main.yml
+++ b/roles/common/tasks/main.yml
@@ -1,3 +1,4 @@
---
- include: sysctl.yml tags=sysctl
- include: hosts.yml
+- include: apt.yml tags=apt