Debian / Ubuntu Linux: Send Automatic Email Notification When Security Upgrades Available

h‮t‬tps://www.lautturi.com
Debian / Ubuntu Linux: Send Automatic Email Notification When Security Upgrades Available

To send automatic email notifications when security upgrades are available on a Debian or Ubuntu Linux system, you can use the unattended-upgrades package. This package allows you to automatically install security upgrades on your system, and it can also send email notifications when new security upgrades are available.

To install the unattended-upgrades package on Debian or Ubuntu, you can use the apt-get command, as shown below:

apt-get install unattended-upgrades

After installing the unattended-upgrades package, you can configure it to send email notifications when security upgrades are available. To do this, edit the /etc/apt/apt.conf.d/50unattended-upgrades file and set the Unattended-Upgrade::Mail option to the email address where you want to receive the notifications. For example:

Unattended-Upgrade::Mail "root@example.com";

You can also customize the subject and body of the email notifications by setting the Unattended-Upgrade::MailOnlyOnError and Unattended-Upgrade::MailSubject options in the configuration file.

Once you have configured the unattended-upgrades package, it will automatically install security upgrades on your system, and it will send email notifications when new security upgrades are available. This can help to keep your system up to date and secure, without requiring you to manually check for and install security upgrades.

Created Time:2017-10-16 14:38:42  Author:lautturi