File tree Expand file tree Collapse file tree 3 files changed +48
-0
lines changed Expand file tree Collapse file tree 3 files changed +48
-0
lines changed Original file line number Diff line number Diff line change @@ -58,3 +58,37 @@ want to preserve.
58
58
# If the URL is missing logs will not be shipped to Papertrail.
59
59
papertrail_url : logsN.papertrailapp.com:NNNNN
60
60
` ` `
61
+
62
+ ## Unattended Upgrades
63
+
64
+ Unattended-upgrades is a package that allows automatic installation of security updates on Debian-based systems.
65
+ The ` unattended-upgrades.yml` task configures unattended-upgrades to ensure that security updates are applied automatically.
66
+
67
+ This service is enabled by default on Ubuntu, but the task ensures it wasn't
68
+ disabled.
69
+
70
+ # ## Monitoring
71
+
72
+ Log files :
73
+
74
+ - ` /var/log/dpkg.log`
75
+ - ` /var/log/unattended-upgrades/`
76
+
77
+ Check the status of unattended-upgrades with :
78
+
79
+ ` ` ` bash
80
+ sudo systemctl status unattended-upgrades
81
+ ` ` `
82
+
83
+ # ## Tips
84
+
85
+ To test the outcome of unattended-upgrades without making any changes, you can run the following command :
86
+
87
+ ` ` ` bash
88
+ sudo unattended-upgrades --dry-run --debug
89
+ ` ` `
90
+
91
+ # ## Docs
92
+
93
+ - [Ubuntu help](https://help.ubuntu.com/community/AutomaticSecurityUpdates)
94
+ - [Debian wiki](https://wiki.debian.org/UnattendedUpgrades)
Original file line number Diff line number Diff line change 9
9
- include_tasks : papertrail.yml
10
10
- include_tasks : cleanup.yml
11
11
- include_tasks : services.yml
12
+ - include_tasks : unattended-upgrades.yml
Original file line number Diff line number Diff line change
1
+ ---
2
+
3
+ # The default configuration of unattended-upgrades is to install security updates only.
4
+ - name : install the unattended-upgrades package
5
+ apt :
6
+ name : unattended-upgrades
7
+ state : present
8
+
9
+ - name : ensure unattended-upgrades is running and enabled
10
+ service :
11
+ name : unattended-upgrades
12
+ state : started
13
+ enabled : yes
You can’t perform that action at this time.
0 commit comments