mirror of
https://github.com/MacRimi/ProxMenux.git
synced 2026-04-05 20:03:48 +00:00
Update notification service
This commit is contained in:
@@ -433,10 +433,13 @@ class EmailChannel(NotificationChannel):
|
||||
try:
|
||||
if self.tls_mode == 'ssl':
|
||||
server = smtplib.SMTP_SSL(self.host, self.port, timeout=self.timeout)
|
||||
server.ehlo()
|
||||
else:
|
||||
server = smtplib.SMTP(self.host, self.port, timeout=self.timeout)
|
||||
server.ehlo()
|
||||
if self.tls_mode == 'starttls':
|
||||
server.starttls()
|
||||
server.ehlo() # Re-identify after TLS upgrade
|
||||
|
||||
if self.username and self.password:
|
||||
server.login(self.username, self.password)
|
||||
|
||||
@@ -1780,7 +1780,7 @@ class PollingCollector:
|
||||
'security_count': str(len(security_pkgs)),
|
||||
'pve_count': str(len(pve_pkgs)),
|
||||
'kernel_count': str(len(kernel_pkgs)),
|
||||
'important_list': '\n'.join(important_lines) if important_lines else 'none',
|
||||
'important_list': '\n'.join(f' {l}' for l in important_lines) if important_lines else 'none',
|
||||
'package_list': ', '.join(important_lines[:6]) if important_lines else '',
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user