Documentation ¶
Overview ¶
Package env is a utility package for env.
Index ¶
- func Env() *utilEnv
- type AlibabaEnv
- func (e *AlibabaEnv) AccessKeyID(_ context.Context) string
- func (e *AlibabaEnv) AccessKeySecret(_ context.Context) string
- func (e *AlibabaEnv) BucketName(_ context.Context) string
- func (e *AlibabaEnv) Config(_ context.Context) map[string]string
- func (e *AlibabaEnv) Endpoint(_ context.Context) string
- func (e *AlibabaEnv) Region(_ context.Context) string
- func (e *AlibabaEnv) String(_ context.Context) string
- type AppEnv
- func (e *AppEnv) Config(_ context.Context) map[string]string
- func (e *AppEnv) Env(_ context.Context) string
- func (e *AppEnv) Environment(_ context.Context) string
- func (e *AppEnv) FrontSite(_ context.Context) string
- func (e *AppEnv) HostIP(_ context.Context) string
- func (e *AppEnv) JaegerEndpoint(_ context.Context) string
- func (e *AppEnv) RoleModel(_ context.Context) string
- func (e *AppEnv) Site(_ context.Context) string
- func (e *AppEnv) String(_ context.Context) string
- func (e *AppEnv) UploadPath(_ context.Context) string
- func (e *AppEnv) Version(_ context.Context) string
- func (e *AppEnv) VisitPath(_ context.Context) string
- type LarkEnv
- func (e *LarkEnv) APPID(_ context.Context) string
- func (e *LarkEnv) APPSecret(_ context.Context) string
- func (e *LarkEnv) Config(_ context.Context) map[string]string
- func (e *LarkEnv) CustomBotSecret(_ context.Context) string
- func (e *LarkEnv) CustomBotWebHookURL(_ context.Context) string
- func (e *LarkEnv) EncryptKey(_ context.Context) string
- func (e *LarkEnv) String(_ context.Context) string
- func (e *LarkEnv) VerificationToken(_ context.Context) string
- type OSSEnv
- func (e *OSSEnv) AccessKeyID(_ context.Context) string
- func (e *OSSEnv) AccessKeySecret(_ context.Context) string
- func (e *OSSEnv) Bucket(_ context.Context) string
- func (e *OSSEnv) Config(_ context.Context) map[string]string
- func (e *OSSEnv) Domain(_ context.Context) string
- func (e *OSSEnv) Endpoint(_ context.Context) string
- func (e *OSSEnv) String(_ context.Context) string
- type SnowflakeEnv
- type TencentEnv
- func (e *TencentEnv) Config(_ context.Context) map[string]string
- func (e *TencentEnv) Endpoint(_ context.Context) string
- func (e *TencentEnv) Region(_ context.Context) string
- func (e *TencentEnv) SecretID(_ context.Context) string
- func (e *TencentEnv) SecretKey(_ context.Context) string
- func (e *TencentEnv) String(_ context.Context) string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AlibabaEnv ¶
type AlibabaEnv struct {
// contains filtered or unexported fields
}
AlibabaEnv .
func (*AlibabaEnv) AccessKeyID ¶
func (e *AlibabaEnv) AccessKeyID(_ context.Context) string
AccessKeyID .
func (*AlibabaEnv) AccessKeySecret ¶
func (e *AlibabaEnv) AccessKeySecret(_ context.Context) string
AccessKeySecret .
func (*AlibabaEnv) BucketName ¶
func (e *AlibabaEnv) BucketName(_ context.Context) string
BucketName .
type AppEnv ¶
type AppEnv struct {
// contains filtered or unexported fields
}
AppEnv .
func (*AppEnv) JaegerEndpoint ¶
JaegerEndpoint .
type LarkEnv ¶
type LarkEnv struct {
// contains filtered or unexported fields
}
LarkEnv lark environment.
func (*LarkEnv) CustomBotSecret ¶
CustomBotSecret .
func (*LarkEnv) CustomBotWebHookURL ¶
CustomBotWebHookURL .
type OSSEnv ¶
type OSSEnv struct {
// contains filtered or unexported fields
}
OSSEnv is the environment variable for oss
func (*OSSEnv) AccessKeyID ¶
AccessKeyID get access key id
func (*OSSEnv) AccessKeySecret ¶
AccessKeySecret get access key secret
type SnowflakeEnv ¶
type SnowflakeEnv struct {
// contains filtered or unexported fields
}
SnowflakeEnv .
func NewSnowflakeEnv ¶
func NewSnowflakeEnv(ctx context.Context) (*SnowflakeEnv, error)
NewSnowflakeEnv .
func (*SnowflakeEnv) Datacenter ¶
func (e *SnowflakeEnv) Datacenter(_ context.Context) int64
Datacenter .
type TencentEnv ¶
type TencentEnv struct {
// contains filtered or unexported fields
}
TencentEnv .
Source Files ¶
Click to show internal directories.
Click to hide internal directories.