feat(o45): add configuration files for o45 host and update apt tasks for compatibility
This commit is contained in:
@@ -224,28 +224,20 @@
|
||||
tags:
|
||||
- unattended-upgrades
|
||||
|
||||
- name: (basic.yml) check if /etc/apt/apt.conf.d/20auto-upgrades exists
|
||||
ansible.builtin.stat:
|
||||
path: /etc/apt/apt.conf.d/20auto-upgrades
|
||||
register: common_ua_enabled
|
||||
- name: (basic.yml) configure auto-upgrades periodic settings
|
||||
ansible.builtin.copy:
|
||||
dest: /etc/apt/apt.conf.d/20auto-upgrades
|
||||
content: |
|
||||
APT::Periodic::Update-Package-Lists "1";
|
||||
APT::Periodic::Unattended-Upgrade "1";
|
||||
owner: root
|
||||
group: root
|
||||
mode: "0644"
|
||||
when:
|
||||
- ansible_facts['distribution'] == "Debian"
|
||||
tags:
|
||||
- unattended-upgrades
|
||||
|
||||
- name: (basic.yml) activate unattended upgrades
|
||||
ansible.builtin.command:
|
||||
cmd: dpkg-reconfigure -plow unattended-upgrades
|
||||
creates: /etc/apt/apt.conf.d/20auto-upgrades
|
||||
environment:
|
||||
DEBIAN_FRONTEND: noninteractive
|
||||
DEBCONF_NONINTERACTIVE_SEEN: "true"
|
||||
when:
|
||||
- ansible_facts['distribution'] == "Debian"
|
||||
- not common_ua_enabled.stat.exists
|
||||
tags:
|
||||
- unattended-upgrades
|
||||
|
||||
- name: (basic.yml) copy apt-listchanges.conf
|
||||
ansible.builtin.template:
|
||||
src: etc/apt/listchanges.conf.j2
|
||||
|
||||
Reference in New Issue
Block a user