-
Notifications
You must be signed in to change notification settings - Fork 1
/
template_config.py
63 lines (60 loc) · 1.96 KB
/
template_config.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
#!/usr/bin/env python
# encoding: utf-8
# coding style: pep8
# ====================================================
# Copyright (C)2016 All rights reserved.
#
# Author : bbxytl
# Email : [email protected]
# File Name : config.py
# Last Modified : 2016-08-31 19:40
# Describe :
#
# Log :
#
# ====================================================
# import sys
import os
config_data = {
# host="TODO: 填写SMTP, eg:smtp.xxx.com"
# "host":"smtp.exmail.qq.com"
# 编号从 1 开始
# postfix="TODO:改成邮箱后缀,eg: gamil.com"
# "postfix":"175game.com" ,
# server_type='TODO: 如果是user中需要带@的全称的,此处为 eim, 否则,为邮箱后缀'
# "server_type" : "eim" ,
# 如果只使用一个邮箱,可以将其他的邮箱类型注释掉,也可以在后面添加除这四种以外的其他邮箱
"host":{
1: {"server_type":"eim", "postfix": "175game.com", "host": "smtp.exmail.qq.com"},
2: {"server_type":"163", "postfix": "163.com", "host": "smtp.163.com" },
3: {"server_type":"126", "postfix": "126.com", "host": "smtp.126.com" },
4: {"server_type":"qq", "postfix": "qq.com", "host": "smtp.qq.com" },
},
# user="TODO: 改成自己的邮箱, @前面的部分 ,eg: 完整邮箱为:[email protected],user 填写 xyz",
# 在 host 开启了 2,3,4 时,这里最好不填
# 如:"user":"tl0485"
"user":""
,
# show_user_name = "TODO: 改成自己的名字"
"show_user_name" : ""
,
# pwd="TODO:改成自己的密码"
"pwd":""
,
# 是否备份邮件(发给自己一份)
"backup" : 0
,
# 默认的收件人列表
"receivers" : [
# TODO:添加收件人 eg: "[email protected]",
]
,
# 邮件log
# 个人目录下可修改此 log 目录
"log_path" : os.environ["HOME"] + '/.mail_send.log'
}
def get_config():
# 默认内容
# config_data["subject"] = "subject:_from:" + config_data["show_user_name"] + "(" + config_data["user"] + ")"
# config_data["content"] = "Content____"
return config_data