2019-09-14 11:49:23 -05:00
|
|
|
#!/usr/bin/ansible-playbook
|
|
|
|
# vim:ft=ansible:
|
|
|
|
---
|
|
|
|
- name: Update and upgrade apt packages
|
|
|
|
apt:
|
2020-02-20 04:02:01 -06:00
|
|
|
upgrade: "yes"
|
2019-09-14 11:49:23 -05:00
|
|
|
update_cache: yes
|
|
|
|
# One day
|
|
|
|
cache_valid_time: 86400
|
2020-02-05 21:13:04 -06:00
|
|
|
become: yes
|
2019-09-14 11:49:23 -05:00
|
|
|
- name: Install basic packages
|
|
|
|
apt:
|
|
|
|
name: "{{ packages }}"
|
|
|
|
vars:
|
|
|
|
packages:
|
2020-04-26 01:39:40 -05:00
|
|
|
- acl
|
2020-02-11 04:18:14 -06:00
|
|
|
- aptitude
|
2019-10-11 19:12:00 -05:00
|
|
|
- python-apt
|
|
|
|
- vim
|
2020-02-05 21:13:04 -06:00
|
|
|
become: yes
|
2020-03-26 10:00:22 -05:00
|
|
|
- name: Configure MOTD
|
|
|
|
block:
|
|
|
|
- name: Disable MOTD news
|
|
|
|
copy:
|
|
|
|
src: "motd-news"
|
|
|
|
dest: "/etc/default/motd-news"
|
|
|
|
- name: Disable default update-motd tasks
|
|
|
|
file:
|
|
|
|
path: "/etc/update-motd.d/{{ item }}"
|
2020-04-15 08:34:32 -05:00
|
|
|
state: absent
|
2020-03-26 10:00:22 -05:00
|
|
|
loop:
|
|
|
|
- "00-header"
|
|
|
|
- "10-help-text"
|
|
|
|
- "50-landscape-sysinfo"
|
|
|
|
- "50-motd-news"
|
|
|
|
- "80-esm"
|
|
|
|
- "80-livepatch"
|
|
|
|
- "90-updates-available"
|
|
|
|
- "91-release-upgrade"
|
|
|
|
- "92-unattended-upgrades"
|
|
|
|
- "95-hwe-eol"
|
|
|
|
- "97-overlayroot"
|
|
|
|
become: yes
|