From 9f23c4a5d97e3daa3c23c0b605adab617ac44c0e Mon Sep 17 00:00:00 2001 From: Gabriel Detraz Date: Mon, 23 Feb 2015 19:25:14 +0100 Subject: [PATCH] ra2.py : bug disconnect destinataire explicite --- gestion/mail/template/deconnex_ra/Cc/fr | 1 + gestion/mail/template/deconnex_ra/From/fr | 2 +- gestion/mail/template/deconnex_ra/body/fr | 2 +- surveillance/ra2.py | 5 +++-- 4 files changed, 6 insertions(+), 4 deletions(-) create mode 100644 gestion/mail/template/deconnex_ra/Cc/fr diff --git a/gestion/mail/template/deconnex_ra/Cc/fr b/gestion/mail/template/deconnex_ra/Cc/fr new file mode 100644 index 00000000..f630a39a --- /dev/null +++ b/gestion/mail/template/deconnex_ra/Cc/fr @@ -0,0 +1 @@ +{{Cc}} diff --git a/gestion/mail/template/deconnex_ra/From/fr b/gestion/mail/template/deconnex_ra/From/fr index 26f7a28b..5bd3e332 100644 --- a/gestion/mail/template/deconnex_ra/From/fr +++ b/gestion/mail/template/deconnex_ra/From/fr @@ -1 +1 @@ -Les nounous du Crans +Les nounous du Crans diff --git a/gestion/mail/template/deconnex_ra/body/fr b/gestion/mail/template/deconnex_ra/body/fr index ed168e82..27d0d4b2 100644 --- a/gestion/mail/template/deconnex_ra/body/fr +++ b/gestion/mail/template/deconnex_ra/body/fr @@ -7,7 +7,7 @@ Celle-ci émet des annonces signalant aux autres machines qu'elle peut gérer le internet. Ceci est normalement réservé au routeur du réseau. Cela en compromet donc la stabilité, et peut impacter les autres utilisateurs. -Pour plus d'information, tu peux nous contacter via diconnect@crans.org. +Pour plus d'information, tu peux nous contacter via disconnect@lists.crans.org. -- diff --git a/surveillance/ra2.py b/surveillance/ra2.py index bc33e99a..6627315a 100755 --- a/surveillance/ra2.py +++ b/surveillance/ra2.py @@ -69,9 +69,9 @@ def ra_blacklist(Mac_ra): # On envoie une notification à disconnect et à la personne : def send_mail(machine): adh = machine.proprio() - From = 'disconnect@crans.org' + From = 'disconnect@lists.crans.org' To = adh.get_mail() - Cc = 'disconnect@crans.org' + Cc = 'disconnect@lists.crans.org' name = adh.ldap_name mach = unicode(machine['host'][0]) if isinstance(adh, lc_ldap.objets.adherent): @@ -80,6 +80,7 @@ def send_mail(machine): tname = unicode(adh['nom'][0]) mailtxt = mail.generate('deconnex_ra', { 'To': To, + 'Cc': Cc, 'From': From, 'tname': tname, 'mach': mach,