2022-07-23 22:15:39 +02:00
|
|
|
---
|
|
|
|
# tasks for all hosts
|
|
|
|
|
|
|
|
- hosts: all
|
|
|
|
become: true
|
|
|
|
|
|
|
|
vars:
|
|
|
|
ansible_python_interpreter: /usr/bin/python3
|
|
|
|
|
|
|
|
roles:
|
|
|
|
- role: ansible.timezone
|
2022-11-07 16:35:41 +01:00
|
|
|
vars:
|
|
|
|
ag_timezone: "{{ timezone }}"
|
2022-07-23 22:15:39 +02:00
|
|
|
|
|
|
|
tasks:
|
|
|
|
- name: Update and clean package cache
|
|
|
|
apt:
|
|
|
|
update_cache: true
|
|
|
|
cache_valid_time: 3600
|
|
|
|
autoclean: true
|
|
|
|
changed_when: false
|
|
|
|
|
|
|
|
- name: Ensure unattended-upgrades is installed and up to date
|
|
|
|
apt:
|
|
|
|
name: unattended-upgrades
|
|
|
|
state: present
|
|
|
|
|
|
|
|
- name: Setup unattended-upgrades
|
|
|
|
include_role:
|
2022-09-30 22:23:44 +02:00
|
|
|
name: hifis.unattended_upgrades
|
2022-07-23 22:15:39 +02:00
|
|
|
vars:
|
|
|
|
unattended_origins_patterns:
|
2022-09-30 22:23:44 +02:00
|
|
|
- "origin=Debian,archive={{ ansible_distribution_release }}-security"
|
|
|
|
- "o=Debian,a={{ ansible_distribution_release }}-updates"
|
2022-07-23 22:15:39 +02:00
|
|
|
unattended_package_blacklist: [cowsay]
|
|
|
|
unattended_mail: "root"
|
|
|
|
|
2022-11-14 16:08:37 +01:00
|
|
|
- name: Install some common software packages
|
|
|
|
ansible.builtin.apt:
|
|
|
|
state: present
|
|
|
|
name:
|
|
|
|
- molly-guard
|
|
|
|
- mc
|
|
|
|
|
|
|
|
|
2022-07-23 22:15:39 +02:00
|
|
|
- name: Setup users
|
|
|
|
include_role:
|
|
|
|
name: users
|