mirror of
https://github.com/openimsdk/open-im-server.git
synced 2026-05-03 16:45:59 +08:00
增加 AWS S3 存储
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
package base_info
|
||||
|
||||
type AwsStorageCredentialReq struct {
|
||||
OperationID string `json:"operationID"`
|
||||
}
|
||||
|
||||
type AwsStorageCredentialRespData struct {
|
||||
AccessKeyId string `json:"accessKeyID"`
|
||||
SecretAccessKey string `json:"secretAccessKey"`
|
||||
SessionToken string `json:"sessionToken"`
|
||||
RegionID string `json:"regionId"`
|
||||
Bucket string `json:"bucket"`
|
||||
FinalHost string `json:"FinalHost"`
|
||||
}
|
||||
|
||||
type AwsStorageCredentialResp struct {
|
||||
CommResp
|
||||
CosData AwsStorageCredentialRespData
|
||||
Data map[string]interface{} `json:"data"`
|
||||
}
|
||||
@@ -73,6 +73,16 @@ type config struct {
|
||||
EndpointInnerEnable bool `yaml:"endpointInnerEnable"`
|
||||
StorageTime int `yaml:"storageTime"`
|
||||
} `yaml:"minio"`
|
||||
Aws struct {
|
||||
AccessKeyID string `yaml:"accessKeyID"`
|
||||
AccessKeySecret string `yaml:"accessKeySecret"`
|
||||
Region string `yaml:"region"`
|
||||
Bucket string `yaml:"bucket"`
|
||||
FinalHost string `yaml:"finalHost"`
|
||||
RoleArn string `yaml:"roleArn"`
|
||||
ExternalId string `yaml:"externalId"`
|
||||
RoleSessionName string `yaml:"roleSessionName"`
|
||||
} `yaml:"aws"`
|
||||
}
|
||||
|
||||
Dtm struct {
|
||||
|
||||
@@ -184,7 +184,8 @@ const (
|
||||
|
||||
//Minio
|
||||
MinioDurationTimes = 3600
|
||||
|
||||
//Aws
|
||||
AwsDurationTimes = 3600
|
||||
// verificationCode used for
|
||||
VerificationCodeForRegister = 1
|
||||
VerificationCodeForReset = 2
|
||||
|
||||
Reference in New Issue
Block a user