pcm-hpc/config/config.go

60 lines
1.8 KiB
Go

package config
type Config struct {
AdapterId int `yaml:"AdapterId"`
Adapter Adapter `yaml:"Adapter"`
CoreClientConf CoreClientConf `yaml:"CoreClientConf"`
ACClientConf ACClientConf `yaml:"ACClientConf"`
SlurmClientConf SlurmClientConf `yaml:"SlurmClientConf"`
ParateraClientConf ParateraClientConf `yaml:"ParateraClientConf"`
}
type Adapter struct {
Name string `yaml:"Name"`
Address string `yaml:"Address"`
RpcAddress string `yaml:"RpcAddress"`
Type string `yaml:"Type"`
TenantId int `yaml:"TenantId"`
TenantName string `yaml:"TenantName"`
Labels Labels `yaml:"Labels"`
MetricsUrl string `yaml:"MetricsUrl"`
}
type Labels struct {
Cloud string `yaml:"cloud"`
}
type CoreClientConf struct {
Url string `yaml:"Url"`
DataSource string `yaml:"DataSource"`
}
type ACClientConf struct {
ClusterUrl string `yaml:"ClusterUrl"`
TokenUrl string `yaml:"TokenUrl"`
StateUrl string `yaml:"StateUrl"`
User string `yaml:"User"`
Password string `yaml:"Password"`
OrgId string `yaml:"OrgId"`
EndPoint string `yaml:"EndPoint"`
Token string `yaml:"Token"`
ClusterID string `yaml:"ClusterID"`
BaseEndpoint string `yaml:"BaseEndpoint"`
}
type SlurmClientConf struct {
URL string `yaml:"URL"`
AdaptMode string `yaml:"AdaptMode"`
ClientVersion string `yaml:"ClientVersion"`
RestUserName string `yaml:"RestUserName"`
CmdUserName string `yaml:"CmdUserName"`
Password string `yaml:"Password"`
Token string `yaml:"Token"`
}
type ParateraClientConf struct {
Url string `yaml:"Url"`
TokenType string `yaml:"TokenType"`
ThirdParty string `yaml:"ThirdParty"`
Phone string `yaml:"Phone"`
Password string `yaml:"Password"`
}