parent
02e3d542b6
commit
49bb6eada3
|
@ -1,6 +1,9 @@
|
|||
changes log
|
||||
======================================
|
||||
------------------------------
|
||||
1.0.2 2024-03-19
|
||||
|
||||
增加发送邮件的身份认证
|
||||
------------------------------
|
||||
1.0.1 2023-11-28
|
||||
|
||||
|
|
|
@ -42,7 +42,7 @@ need_sendmail = False
|
|||
|
||||
def send_mail():
|
||||
# 发件人
|
||||
sender = 'mh@unamail.com'
|
||||
sender = config["receivers"][0]
|
||||
# 接收邮件,可以发给多人
|
||||
receivers = config["receivers"]
|
||||
# 邮件主体
|
||||
|
@ -72,6 +72,8 @@ def send_mail():
|
|||
|
||||
try:
|
||||
smtpObj = smtplib.SMTP('10.10.110.102')
|
||||
#身份认证
|
||||
smtpObj.login(sender,"111111")
|
||||
smtpObj.sendmail(sender, receivers, msg.as_string())
|
||||
print("邮件发送成功")
|
||||
except smtplib.SMTPException:
|
||||
|
|
4
tox.ini
4
tox.ini
|
@ -31,7 +31,7 @@ deps =
|
|||
-r{toxinidir}/requirements.txt
|
||||
|
||||
commands =
|
||||
{envpython} {toxinidir}/release.py {envdir} {envsitepackagesdir} {toxinidir}/build/check_system_info_v1.0.1 {toxinidir}
|
||||
{envpython} {toxinidir}/release.py {envdir} {envsitepackagesdir} {toxinidir}/build/check_system_info_v1.0.2 {toxinidir}
|
||||
|
||||
|
||||
|
||||
|
@ -42,5 +42,5 @@ deps =
|
|||
-r{toxinidir}/requirements.txt
|
||||
|
||||
commands =
|
||||
{envpython} {toxinidir}/release.py {envdir} {envsitepackagesdir} {toxinidir}/build/check_system_info_v1.0.1 {toxinidir}
|
||||
{envpython} {toxinidir}/release.py {envdir} {envsitepackagesdir} {toxinidir}/build/check_system_info_v1.0.2 {toxinidir}
|
||||
|
||||
|
|
Loading…
Reference in New Issue