mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-04-06 04:15:46 +08:00
fix bug and add reset pwd api
This commit is contained in:
parent
079efe5de6
commit
a3fb32dfc6
@ -1,47 +1,47 @@
|
|||||||
# The class cannot be named by Pascal or camel case.
|
# The class cannot be named by Pascal or camel case.
|
||||||
# If it is not used, the corresponding structure will not be set,
|
# If it is not used, the corresponding structure will not be set,
|
||||||
# and it will not be read naturally.
|
# and it will not be read naturally.
|
||||||
serverversion: 3.0.0
|
serverversion: 1.0.3
|
||||||
#---------------Infrastructure configuration---------------------#
|
#---------------Infrastructure configuration---------------------#
|
||||||
etcd:
|
etcd:
|
||||||
etcdSchema: openIM #默认即可
|
etcdSchema: openIM
|
||||||
etcdAddr: [ 127.0.0.1:2379 ] #单机部署时,默认即可
|
etcdAddr: [ 127.0.0.1:2379 ]
|
||||||
|
|
||||||
mysql:
|
mysql:
|
||||||
dbMysqlAddress: [ 127.0.0.1:13306 ] #mysql地址 目前仅支持单机,默认即可
|
dbMysqlAddress: [ 127.0.0.1:13306 ]
|
||||||
dbMysqlUserName: root #mysql用户名,建议修改
|
dbMysqlUserName: root
|
||||||
dbMysqlPassword: openIM # mysql密码,建议修改
|
dbMysqlPassword: openIM
|
||||||
dbMysqlDatabaseName: openIM #默认即可
|
dbMysqlDatabaseName: openIM
|
||||||
dbTableName: eMsg #默认即可
|
dbTableName: eMsg
|
||||||
dbMsgTableNum: 1
|
dbMsgTableNum: 1
|
||||||
dbMaxOpenConns: 20
|
dbMaxOpenConns: 20
|
||||||
dbMaxIdleConns: 10
|
dbMaxIdleConns: 10
|
||||||
dbMaxLifeTime: 120
|
dbMaxLifeTime: 120
|
||||||
|
|
||||||
mongo:
|
mongo:
|
||||||
dbAddress: [ 127.0.0.1:37017 ] #redis地址 目前仅支持单机,默认即可
|
dbAddress: [ 127.0.0.1:37017 ]
|
||||||
dbDirect: false
|
dbDirect: false
|
||||||
dbTimeout: 10
|
dbTimeout: 10
|
||||||
dbDatabase: openIM #mongo db 默认即可
|
dbDatabase: openIM
|
||||||
dbSource: admin
|
dbSource: admin
|
||||||
dbUserName: #mongo用户名,建议修改
|
dbUserName:
|
||||||
dbPassword: #mongo密码,建议修改
|
dbPassword:
|
||||||
dbMaxPoolSize: 20
|
dbMaxPoolSize: 20
|
||||||
dbRetainChatRecords: 3650 #mongo保存离线消息时间(天)
|
dbRetainChatRecords: 7
|
||||||
|
|
||||||
redis:
|
redis:
|
||||||
dbAddress: 127.0.0.1:16379 #redis地址 目前仅支持单机,默认即可
|
dbAddress: 127.0.0.1:16379
|
||||||
dbMaxIdle: 128
|
dbMaxIdle: 128
|
||||||
dbMaxActive: 0
|
dbMaxActive: 0
|
||||||
dbIdleTimeout: 120
|
dbIdleTimeout: 120
|
||||||
dbPassWord: openIM #redis密码 建议修改
|
dbPassWord: openIM
|
||||||
|
|
||||||
kafka:
|
kafka:
|
||||||
ws2mschat:
|
ws2mschat:
|
||||||
addr: [ 127.0.0.1:9092 ] #kafka配置,默认即可
|
addr: [ 127.0.0.1:9092 ]
|
||||||
topic: "ws2ms_chat"
|
topic: "ws2ms_chat"
|
||||||
ms2pschat:
|
ms2pschat:
|
||||||
addr: [ 127.0.0.1:9092 ] #kafka配置,默认即可
|
addr: [ 127.0.0.1:9092 ]
|
||||||
topic: "ms2ps_chat"
|
topic: "ms2ps_chat"
|
||||||
consumergroupid:
|
consumergroupid:
|
||||||
msgToMongo: mongo
|
msgToMongo: mongo
|
||||||
@ -55,7 +55,6 @@ kafka:
|
|||||||
# The service ip default is empty,
|
# The service ip default is empty,
|
||||||
# automatically obtain the machine's valid network card ip as the service ip,
|
# automatically obtain the machine's valid network card ip as the service ip,
|
||||||
# otherwise the configuration ip is preferred
|
# otherwise the configuration ip is preferred
|
||||||
#如果是单机模式,用0.0.0.0或者不填,默认即可
|
|
||||||
serverip: 0.0.0.0
|
serverip: 0.0.0.0
|
||||||
|
|
||||||
# endpoints 内部组件间访问的端点host名称,访问时,可以内部直接访问 host:port 来访问
|
# endpoints 内部组件间访问的端点host名称,访问时,可以内部直接访问 host:port 来访问
|
||||||
@ -74,22 +73,27 @@ endpoints:
|
|||||||
rpc_message_cms: openim_rpc_admin_cms
|
rpc_message_cms: openim_rpc_admin_cms
|
||||||
|
|
||||||
api:
|
api:
|
||||||
openImApiPort: [ 10000 ] #api服务端口,默认即可,注意开放此端口或做nginx转发
|
openImApiPort: [ 10000 ]
|
||||||
cmsapi:
|
cmsapi:
|
||||||
openImCmsApiPort: [ 8000 ] #管理后台api服务端口,默认即可,注意开放此端口或做nginx转发
|
openImCmsApiPort: [ 8000 ]
|
||||||
sdk:
|
sdk:
|
||||||
openImSdkWsPort: [ 30000 ] #jssdk服务端口,默认即可,项目中使用jssdk才需开放此端口或做nginx转发
|
openImSdkWsPort: [ 30000 ]
|
||||||
|
|
||||||
credential: #腾讯cos,发送图片、视频、文件时需要,请自行申请后替换,必须修改
|
credential:
|
||||||
tencent:
|
tencent:
|
||||||
appID: 1302656840
|
appID: 1302656840
|
||||||
region: ap-chengdu
|
region: ap-chengdu
|
||||||
bucket: echat-1302656840
|
bucket: echat-1302656840
|
||||||
secretID: AKIDGNYVChzIQinu7QEgtNp0hnNgqcV8vZTC
|
secretID: AKIDGNYVChzIQinu7QEgtNp0hnNgqcV8vZTC
|
||||||
secretKey: kz15vW83qM6dBUWIq681eBZA0c0vlIbe
|
secretKey: kz15vW83qM6dBUWIq681eBZA0c0vlIbe
|
||||||
|
minio:
|
||||||
|
bucket: openim
|
||||||
|
location: us-east-1
|
||||||
|
endpoint: http://127.0.0.1:9000
|
||||||
|
accessKeyID: minioadmin
|
||||||
|
secretAccessKey: minioadmin
|
||||||
|
|
||||||
|
rpcport:
|
||||||
rpcport: #rpc服务端口 默认即可
|
|
||||||
openImUserPort: [ 10100 ]
|
openImUserPort: [ 10100 ]
|
||||||
openImFriendPort: [ 10200 ]
|
openImFriendPort: [ 10200 ]
|
||||||
openImOfflineMessagePort: [ 10300 ]
|
openImOfflineMessagePort: [ 10300 ]
|
||||||
@ -110,7 +114,7 @@ rpcport: #rpc服务端口 默认即可
|
|||||||
stateChange:
|
stateChange:
|
||||||
switch: false
|
switch: false
|
||||||
|
|
||||||
rpcregistername: #rpc注册服务名,默认即可
|
rpcregistername:
|
||||||
openImUserName: User
|
openImUserName: User
|
||||||
openImFriendName: Friend
|
openImFriendName: Friend
|
||||||
openImOfflineMessageName: OfflineMessage
|
openImOfflineMessageName: OfflineMessage
|
||||||
@ -125,57 +129,57 @@ rpcregistername: #rpc注册服务名,默认即可
|
|||||||
log:
|
log:
|
||||||
storageLocation: ../logs/
|
storageLocation: ../logs/
|
||||||
rotationTime: 24
|
rotationTime: 24
|
||||||
remainRotationCount: 5 #日志数量
|
remainRotationCount: 5
|
||||||
remainLogLevel: 6 #日志级别 6表示全都打印,测试阶段建议设置为6
|
remainLogLevel: 6
|
||||||
elasticSearchSwitch: false
|
elasticSearchSwitch: false
|
||||||
elasticSearchAddr: [ 127.0.0.1:9201 ]
|
elasticSearchAddr: [ 127.0.0.1:9201 ]
|
||||||
elasticSearchUser: ""
|
elasticSearchUser: ""
|
||||||
elasticSearchPassword: ""
|
elasticSearchPassword: ""
|
||||||
|
|
||||||
modulename: #日志文件按模块命名,默认即可
|
modulename:
|
||||||
longConnSvrName: msg_gateway
|
longConnSvrName: msg_gateway
|
||||||
msgTransferName: msg_transfer
|
msgTransferName: msg_transfer
|
||||||
pushName: push
|
pushName: push
|
||||||
|
|
||||||
longconnsvr:
|
longconnsvr:
|
||||||
openImWsPort: [ 17778 ] # ws服务端口,默认即可,要开放此端口或做nginx转发
|
openImWsPort: [ 17778 ]
|
||||||
websocketMaxConnNum: 10000
|
websocketMaxConnNum: 10000
|
||||||
websocketMaxMsgLen: 4096
|
websocketMaxMsgLen: 4096
|
||||||
websocketTimeOut: 10
|
websocketTimeOut: 10
|
||||||
|
|
||||||
push:
|
push:
|
||||||
tpns: #腾讯推送,暂未测试 暂不要使用
|
tpns:
|
||||||
ios:
|
ios:
|
||||||
accessID: 1600018281
|
accessID: 1600018281
|
||||||
secretKey: 3cd68a77a95b89e5089a1aca523f318f
|
secretKey: 3cd68a77a95b89e5089a1aca523f318f
|
||||||
android:
|
android:
|
||||||
accessID: 111
|
accessID: 111
|
||||||
secretKey: 111
|
secretKey: 111
|
||||||
jpns: #极光推送 在极光后台申请后,修改以下四项,必须修改
|
jpns:
|
||||||
appKey: cf47465a368f24c659608e7e
|
appKey: cf47465a368f24c659608e7e
|
||||||
masterSecret: 02204efe3f3832947a236ee5
|
masterSecret: 02204efe3f3832947a236ee5
|
||||||
pushUrl: "https://api.jpush.cn/v3/push"
|
pushUrl: "https://api.jpush.cn/v3/push"
|
||||||
pushIntent: "intent:#Intent;component=io.openim.app.enterprisechat/io.openim.app.enterprisechat.MainActivity;end"
|
pushIntent: "intent:#Intent;component=io.openim.app.enterprisechat/io.openim.app.enterprisechat.MainActivity;end"
|
||||||
manager:
|
manager:
|
||||||
#app管理员userID和对应的secret 建议修改。 用于管理后台登录,也可以用户管理后台对应的api
|
|
||||||
appManagerUid: [ "openIM123456","openIM654321", "openIM333", "openIMAdmin"]
|
appManagerUid: [ "openIM123456","openIM654321", "openIM333", "openIMAdmin"]
|
||||||
secrets: [ "openIM1","openIM2", "openIM333", "openIMAdmin"]
|
secrets: [ "openIM1","openIM2", "openIM333", "openIMAdmin"]
|
||||||
|
|
||||||
secret: tuoyun
|
secret: tuoyun
|
||||||
# 多端互踢策略
|
|
||||||
# 1:多平台登录:Android、iOS、Windows、Mac 每种平台只能一个在线,web端可以多个同时在线
|
|
||||||
multiloginpolicy: 1
|
multiloginpolicy: 1
|
||||||
|
|
||||||
#token config
|
#token config
|
||||||
tokenpolicy:
|
tokenpolicy:
|
||||||
accessSecret: "open_im_server" #token生成相关,默认即可
|
accessSecret: "open_im_server"
|
||||||
# Token effective time day as a unit
|
# Token effective time day as a unit
|
||||||
accessExpire: 3650 #token过期时间(天)
|
accessExpire: 7
|
||||||
|
|
||||||
messagecallback: #暂时不要使用 还需完善
|
messagecallback:
|
||||||
callbackUrl: "http://www.xxx.com/msg/judge"
|
callbackUrl: "http://www.xxx.com/msg/judge"
|
||||||
#TimeOut use second as unit
|
#TimeOut use second as unit
|
||||||
callbackTimeOut: 10
|
callbackTimeOut: 10
|
||||||
|
messagejudge:
|
||||||
|
isJudgeFriend: true
|
||||||
# c2c:
|
# c2c:
|
||||||
# callbackBeforeSendMsg:
|
# callbackBeforeSendMsg:
|
||||||
# switch: false
|
# switch: false
|
||||||
@ -185,7 +189,7 @@ messagecallback: #暂时不要使用 还需完善
|
|||||||
# state:
|
# state:
|
||||||
# stateChange:
|
# stateChange:
|
||||||
# switch: false
|
# switch: false
|
||||||
#ios系统推送声音以及标记计数
|
|
||||||
iospush:
|
iospush:
|
||||||
pushSound: "xxx"
|
pushSound: "xxx"
|
||||||
badgeCount: true
|
badgeCount: true
|
||||||
@ -249,7 +253,7 @@ notification:
|
|||||||
desc: "groupApplicationAccepted desc"
|
desc: "groupApplicationAccepted desc"
|
||||||
ext: "groupApplicationAccepted ext"
|
ext: "groupApplicationAccepted ext"
|
||||||
defaultTips:
|
defaultTips:
|
||||||
tips: "allowed to join the group" # group info changed by xx
|
tips: "was allowed to join the group" # group info changed by xx
|
||||||
|
|
||||||
groupApplicationRejected:
|
groupApplicationRejected:
|
||||||
conversation:
|
conversation:
|
||||||
@ -261,7 +265,7 @@ notification:
|
|||||||
desc: " desc"
|
desc: " desc"
|
||||||
ext: " ext"
|
ext: " ext"
|
||||||
defaultTips:
|
defaultTips:
|
||||||
tips: "rejected into the group" # group info changed by xx
|
tips: "was rejected into the group" # group info changed by xx
|
||||||
|
|
||||||
groupOwnerTransferred:
|
groupOwnerTransferred:
|
||||||
conversation:
|
conversation:
|
||||||
@ -285,7 +289,7 @@ notification:
|
|||||||
desc: "memberKicked desc"
|
desc: "memberKicked desc"
|
||||||
ext: "memberKicked ext"
|
ext: "memberKicked ext"
|
||||||
defaultTips:
|
defaultTips:
|
||||||
tips: "kicked out of the group" # group info changed by xx
|
tips: "was kicked out of the group" # group info changed by xx
|
||||||
|
|
||||||
memberInvited:
|
memberInvited:
|
||||||
conversation:
|
conversation:
|
||||||
@ -297,7 +301,7 @@ notification:
|
|||||||
desc: "memberInvited desc"
|
desc: "memberInvited desc"
|
||||||
ext: "memberInvited ext"
|
ext: "memberInvited ext"
|
||||||
defaultTips:
|
defaultTips:
|
||||||
tips: "invited into the group" # group info changed by xx
|
tips: "was invited into the group" # group info changed by xx
|
||||||
|
|
||||||
memberEnter:
|
memberEnter:
|
||||||
conversation:
|
conversation:
|
||||||
@ -374,11 +378,11 @@ notification:
|
|||||||
unreadCount: false
|
unreadCount: false
|
||||||
offlinePush:
|
offlinePush:
|
||||||
switch: true
|
switch: true
|
||||||
title: "deleted a friend"
|
title: "Deleted a friend"
|
||||||
desc: "deleted a friend"
|
desc: "Deleted a friend"
|
||||||
ext: "deleted a friend"
|
ext: "Deleted a friend"
|
||||||
defaultTips:
|
defaultTips:
|
||||||
tips: "deleted a friend" #
|
tips: "Deleted a friend" #
|
||||||
|
|
||||||
|
|
||||||
friendRemarkSet:
|
friendRemarkSet:
|
||||||
@ -401,11 +405,11 @@ notification:
|
|||||||
unreadCount: false
|
unreadCount: false
|
||||||
offlinePush:
|
offlinePush:
|
||||||
switch: true
|
switch: true
|
||||||
title: "blocked a user"
|
title: "Blocked a user"
|
||||||
desc: "blocked a user"
|
desc: "Blocked a user"
|
||||||
ext: "blocked a user"
|
ext: "Blocked a user"
|
||||||
defaultTips:
|
defaultTips:
|
||||||
tips: "blocked a user" #
|
tips: "Blocked a user" #
|
||||||
|
|
||||||
|
|
||||||
blackDeleted:
|
blackDeleted:
|
||||||
@ -431,7 +435,7 @@ notification:
|
|||||||
desc: "Remove a blocked user"
|
desc: "Remove a blocked user"
|
||||||
ext: "Remove a blocked user"
|
ext: "Remove a blocked user"
|
||||||
defaultTips:
|
defaultTips:
|
||||||
tips: "remove a blocked user"
|
tips: "Remove a blocked user"
|
||||||
|
|
||||||
#####################conversation#########################
|
#####################conversation#########################
|
||||||
conversationOptUpdate:
|
conversationOptUpdate:
|
||||||
@ -450,24 +454,23 @@ notification:
|
|||||||
|
|
||||||
#---------------demo configuration---------------------#
|
#---------------demo configuration---------------------#
|
||||||
#The following configuration items are applied to openIM Demo configuration
|
#The following configuration items are applied to openIM Demo configuration
|
||||||
#是否启动demo,如果自身没有账号体系,设置为true
|
|
||||||
demoswitch: true
|
demoswitch: true
|
||||||
demo:
|
demo:
|
||||||
openImDemoPort: [ 42233 ] #demo对外服务端口,默认即可,需要开放此端口或做nginx转发
|
openImDemoPort: [ 42233 ]
|
||||||
alismsverify: #阿里云短信配置,在阿里云申请成功后修改以下四项,必须修改
|
alismsverify:
|
||||||
accessKeyId: LTAI5tJPkn4HuuePdiLdGqe71
|
accessKeyId: LTAI5tJPkn4HuuePdiLdGqe71
|
||||||
accessKeySecret: 4n9OJ7ZCVN1U6KeHDAtOyNeVZcjOuV1
|
accessKeySecret: 4n9OJ7ZCVN1U6KeHDAtOyNeVZcjOuV1
|
||||||
signName: OpenIM Corporation
|
signName: OpenIM Corporation
|
||||||
verificationCodeTemplateCode: SMS_2268101641
|
verificationCodeTemplateCode: SMS_2268101641
|
||||||
superCode: 666666 #超级验证码,建议修改掉,收不到短信验证码时可以用此替代
|
superCode: 666666
|
||||||
# second
|
# second
|
||||||
codeTTL: 60
|
codeTTL: 60
|
||||||
mail: #仅支持qq邮箱,具体操作参考 https://service.mail.qq.com/cgi-bin/help?subtype=1&id=28&no=1001256 必须修改
|
mail:
|
||||||
title: "openIM"
|
title: "openIM"
|
||||||
senderMail: "1765567899@qq.com"
|
senderMail: "1765567899@qq.com"
|
||||||
senderAuthorizationCode: "1gxyausfoevlzbfag"
|
senderAuthorizationCode: "1gxyausfoevlzbfag"
|
||||||
smtpAddr: "smtp.qq.com"
|
smtpAddr: "smtp.qq.com"
|
||||||
smtpPort: 25 #需开放此端口 出口方向
|
smtpPort: 25
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
20
go.sum
20
go.sum
@ -156,6 +156,7 @@ github.com/go-playground/validator/v10 v10.4.1/go.mod h1:nlOn6nFhuKACm19sB/8EGNn
|
|||||||
github.com/go-sql-driver/mysql v1.5.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg=
|
github.com/go-sql-driver/mysql v1.5.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg=
|
||||||
github.com/go-sql-driver/mysql v1.6.0 h1:BCTh4TKNUYmOmMUcQ3IipzF5prigylS7XXjEkfCHuOE=
|
github.com/go-sql-driver/mysql v1.6.0 h1:BCTh4TKNUYmOmMUcQ3IipzF5prigylS7XXjEkfCHuOE=
|
||||||
github.com/go-sql-driver/mysql v1.6.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg=
|
github.com/go-sql-driver/mysql v1.6.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg=
|
||||||
|
github.com/go-stack/stack v1.8.0 h1:5SgMzNM5HxrEjV0ww2lTmX6E2Izsfxas4+YHWRs3Lsk=
|
||||||
github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY=
|
github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY=
|
||||||
github.com/godbus/dbus/v5 v5.0.3/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA=
|
github.com/godbus/dbus/v5 v5.0.3/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA=
|
||||||
github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA=
|
github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA=
|
||||||
@ -200,6 +201,7 @@ github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaS
|
|||||||
github.com/golang/protobuf v1.5.1/go.mod h1:DopwsBzvsk0Fs44TXzsVbJyPhcCPeIwnvohx4u74HPM=
|
github.com/golang/protobuf v1.5.1/go.mod h1:DopwsBzvsk0Fs44TXzsVbJyPhcCPeIwnvohx4u74HPM=
|
||||||
github.com/golang/protobuf v1.5.2 h1:ROPKBNFfQgOUMifHyP+KYbvpjbdoFNs+aK7DXlji0Tw=
|
github.com/golang/protobuf v1.5.2 h1:ROPKBNFfQgOUMifHyP+KYbvpjbdoFNs+aK7DXlji0Tw=
|
||||||
github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY=
|
github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY=
|
||||||
|
github.com/golang/snappy v0.0.1/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q=
|
||||||
github.com/golang/snappy v0.0.3/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q=
|
github.com/golang/snappy v0.0.3/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q=
|
||||||
github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM=
|
github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM=
|
||||||
github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q=
|
github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q=
|
||||||
@ -311,8 +313,9 @@ github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7V
|
|||||||
github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q=
|
github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q=
|
||||||
github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8=
|
github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8=
|
||||||
github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck=
|
github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck=
|
||||||
github.com/klauspost/compress v1.13.5 h1:9O69jUPDcsT9fEm74W92rZL9FQY7rCdaXVneq+yyzl4=
|
|
||||||
github.com/klauspost/compress v1.13.5/go.mod h1:/3/Vjq9QcHkK5uEr5lBEmyoZ1iFhe47etQ6QUkpK6sk=
|
github.com/klauspost/compress v1.13.5/go.mod h1:/3/Vjq9QcHkK5uEr5lBEmyoZ1iFhe47etQ6QUkpK6sk=
|
||||||
|
github.com/klauspost/compress v1.13.6 h1:P76CopJELS0TiO2mebmnzgWaajssP/EszplttgQxcgc=
|
||||||
|
github.com/klauspost/compress v1.13.6/go.mod h1:/3/Vjq9QcHkK5uEr5lBEmyoZ1iFhe47etQ6QUkpK6sk=
|
||||||
github.com/klauspost/cpuid v1.2.3/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek=
|
github.com/klauspost/cpuid v1.2.3/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek=
|
||||||
github.com/klauspost/cpuid v1.3.1 h1:5JNjFYYQrZeKRJ0734q51WCEEn2huer72Dc7K+R/b6s=
|
github.com/klauspost/cpuid v1.3.1 h1:5JNjFYYQrZeKRJ0734q51WCEEn2huer72Dc7K+R/b6s=
|
||||||
github.com/klauspost/cpuid v1.3.1/go.mod h1:bYW4mA6ZgKPob1/Dlai2LviZJO7KGI3uoWLd42rAQw4=
|
github.com/klauspost/cpuid v1.3.1/go.mod h1:bYW4mA6ZgKPob1/Dlai2LviZJO7KGI3uoWLd42rAQw4=
|
||||||
@ -380,6 +383,7 @@ github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJ
|
|||||||
github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
|
github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
|
||||||
github.com/modern-go/reflect2 v1.0.1 h1:9f412s+6RmYXLWZSEzVVgPGK7C2PphHj5RJrvfx9AWI=
|
github.com/modern-go/reflect2 v1.0.1 h1:9f412s+6RmYXLWZSEzVVgPGK7C2PphHj5RJrvfx9AWI=
|
||||||
github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
|
github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0=
|
||||||
|
github.com/montanaflynn/stats v0.0.0-20171201202039-1bf9dbcd8cbe/go.mod h1:wL8QJuTMNUDYhXwkmfOly8iTdp5TEcJFWZD2D7SIkUc=
|
||||||
github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U=
|
github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U=
|
||||||
github.com/nfnt/resize v0.0.0-20180221191011-83c6a9932646 h1:zYyBkD/k9seD2A7fsi6Oo2LfFZAehjjQMERAvZLEDnQ=
|
github.com/nfnt/resize v0.0.0-20180221191011-83c6a9932646 h1:zYyBkD/k9seD2A7fsi6Oo2LfFZAehjjQMERAvZLEDnQ=
|
||||||
github.com/nfnt/resize v0.0.0-20180221191011-83c6a9932646/go.mod h1:jpp1/29i3P1S/RLdc7JQKbRpFeM1dOBd8T9ki5s+AY8=
|
github.com/nfnt/resize v0.0.0-20180221191011-83c6a9932646/go.mod h1:jpp1/29i3P1S/RLdc7JQKbRpFeM1dOBd8T9ki5s+AY8=
|
||||||
@ -467,6 +471,8 @@ github.com/subosito/gotenv v1.2.0 h1:Slr1R9HxAlEKefgq5jn9U+DnETlIUa6HfgEzj0g5d7s
|
|||||||
github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw=
|
github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw=
|
||||||
github.com/tencentyun/qcloud-cos-sts-sdk v0.0.0-20210325043845-84a0811633ca h1:G/aIr3WiUesWHL2YGYgEqjM5tCAJ43Ml+0C18wDkWWs=
|
github.com/tencentyun/qcloud-cos-sts-sdk v0.0.0-20210325043845-84a0811633ca h1:G/aIr3WiUesWHL2YGYgEqjM5tCAJ43Ml+0C18wDkWWs=
|
||||||
github.com/tencentyun/qcloud-cos-sts-sdk v0.0.0-20210325043845-84a0811633ca/go.mod h1:b18KQa4IxHbxeseW1GcZox53d7J0z39VNONTxvvlkXw=
|
github.com/tencentyun/qcloud-cos-sts-sdk v0.0.0-20210325043845-84a0811633ca/go.mod h1:b18KQa4IxHbxeseW1GcZox53d7J0z39VNONTxvvlkXw=
|
||||||
|
github.com/tidwall/pretty v1.0.0 h1:HsD+QiTn7sK6flMKIvNmpqz1qrpP3Ps6jOKIKMooyg4=
|
||||||
|
github.com/tidwall/pretty v1.0.0/go.mod h1:XNkn88O1ChpSDQmQeStsy+sBenx6DDtFZJxhVysOjyk=
|
||||||
github.com/tjfoc/gmsm v1.3.2 h1:7JVkAn5bvUJ7HtU08iW6UiD+UTmJTIToHCfeFzkcCxM=
|
github.com/tjfoc/gmsm v1.3.2 h1:7JVkAn5bvUJ7HtU08iW6UiD+UTmJTIToHCfeFzkcCxM=
|
||||||
github.com/tjfoc/gmsm v1.3.2/go.mod h1:HaUcFuY0auTiaHB9MHFGCPx5IaLhTUd2atbCFBQXn9w=
|
github.com/tjfoc/gmsm v1.3.2/go.mod h1:HaUcFuY0auTiaHB9MHFGCPx5IaLhTUd2atbCFBQXn9w=
|
||||||
github.com/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U=
|
github.com/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U=
|
||||||
@ -477,8 +483,16 @@ github.com/ugorji/go v1.1.7/go.mod h1:kZn38zHttfInRq0xu/PH0az30d+z6vm202qpg1oXVM
|
|||||||
github.com/ugorji/go/codec v1.1.7 h1:2SvQaVZ1ouYrrKKwoSk2pzd4A9evlKJb9oTL+OaLUSs=
|
github.com/ugorji/go/codec v1.1.7 h1:2SvQaVZ1ouYrrKKwoSk2pzd4A9evlKJb9oTL+OaLUSs=
|
||||||
github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLYF3GoBXY=
|
github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLYF3GoBXY=
|
||||||
github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
|
github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
|
||||||
|
github.com/xdg-go/pbkdf2 v1.0.0 h1:Su7DPu48wXMwC3bs7MCNG+z4FhcyEuz5dlvchbq0B0c=
|
||||||
|
github.com/xdg-go/pbkdf2 v1.0.0/go.mod h1:jrpuAogTd400dnrH08LKmI/xc1MbPOebTwRqcT5RDeI=
|
||||||
|
github.com/xdg-go/scram v1.0.2 h1:akYIkZ28e6A96dkWNJQu3nmCzH3YfwMPQExUYDaRv7w=
|
||||||
|
github.com/xdg-go/scram v1.0.2/go.mod h1:1WAq6h33pAW+iRreB34OORO2Nf7qel3VV3fjBj+hCSs=
|
||||||
|
github.com/xdg-go/stringprep v1.0.2 h1:6iq84/ryjjeRmMJwxutI51F2GIPlP5BfTvXHeYjyhBc=
|
||||||
|
github.com/xdg-go/stringprep v1.0.2/go.mod h1:8F9zXuvzgwmyT5DUm4GUfZGDdT3W+LCvS6+da4O5kxM=
|
||||||
github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2 h1:eY9dn8+vbi4tKz5Qo6v2eYzo7kUS51QINcR5jNpbZS8=
|
github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2 h1:eY9dn8+vbi4tKz5Qo6v2eYzo7kUS51QINcR5jNpbZS8=
|
||||||
github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU=
|
github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU=
|
||||||
|
github.com/youmark/pkcs8 v0.0.0-20181117223130-1be2e3e5546d h1:splanxYIlg+5LfHAM6xpdFEAYOk8iySO56hMFq6uLyA=
|
||||||
|
github.com/youmark/pkcs8 v0.0.0-20181117223130-1be2e3e5546d/go.mod h1:rHwXgn7JulP+udvsHwJoVG1YGAP6VLg4y9I5dyZdqmA=
|
||||||
github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
|
github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
|
||||||
github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
|
github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
|
||||||
github.com/yuin/goldmark v1.1.30/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
|
github.com/yuin/goldmark v1.1.30/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
|
||||||
@ -492,6 +506,8 @@ go.etcd.io/etcd v0.0.0-20200402134248-51bdeb39e698/go.mod h1:YoUyTScD3Vcv2RBm3eG
|
|||||||
go.etcd.io/etcd/api/v3 v3.5.0/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs=
|
go.etcd.io/etcd/api/v3 v3.5.0/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs=
|
||||||
go.etcd.io/etcd/client/pkg/v3 v3.5.0/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g=
|
go.etcd.io/etcd/client/pkg/v3 v3.5.0/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g=
|
||||||
go.etcd.io/etcd/client/v2 v2.305.0/go.mod h1:h9puh54ZTgAKtEbut2oe9P4L/oqKCVB6xsXlzd7alYQ=
|
go.etcd.io/etcd/client/v2 v2.305.0/go.mod h1:h9puh54ZTgAKtEbut2oe9P4L/oqKCVB6xsXlzd7alYQ=
|
||||||
|
go.mongodb.org/mongo-driver v1.8.3 h1:TDKlTkGDKm9kkJVUOAXDK5/fkqKHJVwYQSpoRfB43R4=
|
||||||
|
go.mongodb.org/mongo-driver v1.8.3/go.mod h1:0sQWfOeY63QTntERDJJ/0SuKK0T1uVSgKCuAROlKEPY=
|
||||||
go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU=
|
go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU=
|
||||||
go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8=
|
go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8=
|
||||||
go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
|
go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
|
||||||
@ -628,6 +644,7 @@ golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a/go.mod h1:RxMgew5VJxzue5/jJ
|
|||||||
golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||||
golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||||
golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||||
|
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c h1:5KslGYwFpkhGh+Q16bwMP3cOontH8FOep7tGV86Y7SQ=
|
||||||
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||||
golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||||
golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||||
@ -716,6 +733,7 @@ golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3
|
|||||||
golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
|
golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
|
||||||
golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
|
golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
|
||||||
golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
|
golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
|
||||||
|
golang.org/x/tools v0.0.0-20190531172133-b3315ee88b7d/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
||||||
golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
||||||
golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
||||||
golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
||||||
|
@ -7,7 +7,6 @@ import (
|
|||||||
"context"
|
"context"
|
||||||
"github.com/minio/minio-go/v7"
|
"github.com/minio/minio-go/v7"
|
||||||
"github.com/minio/minio-go/v7/pkg/credentials"
|
"github.com/minio/minio-go/v7/pkg/credentials"
|
||||||
"github.com/minio/minio-go/v7/pkg/policy"
|
|
||||||
url2 "net/url"
|
url2 "net/url"
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -39,10 +38,10 @@ func init() {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
err = minioClient.SetBucketPolicy(context.Background(), config.Config.Credential.Minio.Bucket, policy.BucketPolicyReadWrite)
|
//err = minioClient.SetBucketPolicy(context.Background(), config.Config.Credential.Minio.Bucket, policy.BucketPolicyReadWrite)
|
||||||
if err != nil {
|
//if err != nil {
|
||||||
log.NewError("", utils.GetSelfFuncName(), "SetBucketPolicy failed please set in ", err.Error())
|
// log.NewError("", utils.GetSelfFuncName(), "SetBucketPolicy failed please set in ", err.Error())
|
||||||
return
|
// return
|
||||||
}
|
//}
|
||||||
log.NewInfo("", utils.GetSelfFuncName(), "minio create and set policy success")
|
log.NewInfo("", utils.GetSelfFuncName(), "minio create and set policy success")
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user