Documentation ¶
Overview ¶
Package config 配置模块,由程序入口加载,全局可用
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Datatunnel ¶
type Datatunnel struct {
ExportServices map[string]string `json:"export_services" yaml:"export_services"`
}
type Extension ¶ added in v1.9.1
type Extension struct {
GRPCPort int `json:"grpc_port" yaml:"grpc_port"`
}
func (Extension) GRPCAddress ¶ added in v1.9.1
type Options ¶
type Options struct { Debug bool `json:"debug" yaml:"debug"` SmartCloud SmartCloud `json:"smartcloud" yaml:"smartcloud"` SmartAssistant SmartAssistant `json:"smartassistant" yaml:"smartassistant"` Datatunnel Datatunnel `json:"datatunnel" yaml:"datatunnel"` Extension Extension `json:"extension" yaml:"extension"` }
func InitConfig ¶
type SmartAssistant ¶
type SmartAssistant struct { ID string `json:"id" yaml:"id"` Key string `json:"key" yaml:"key"` Db string `json:"db" yaml:"db"` Host string `json:"host" yaml:"host"` Port int `json:"port" yaml:"port"` GRPCPort int `json:"grpc_port" yaml:"grpc_port"` FluentdAddress string `json:"fluentd_address" yaml:"fluentd_address"` Database Database `json:"database" yaml:"database"` // HostDataPath 宿主机runtime目录 HostRuntimePath string `json:"host_runtime_path" yaml:"host_runtime_path"` RuntimePath string `json:"runtime_path" yaml:"runtime_path"` DockerRegistry string `json:"docker_registry" yaml:"docker_registry"` // Deprecated: HostIP 插件取消host模式后删除 HostIP string `json:"host_ip" yaml:"host_ip"` }
func (SmartAssistant) BackupPath ¶
func (sa SmartAssistant) BackupPath() string
func (SmartAssistant) DataPath ¶
func (sa SmartAssistant) DataPath() string
func (SmartAssistant) GRPCAddress ¶
func (sa SmartAssistant) GRPCAddress() string
func (SmartAssistant) HttpAddress ¶
func (sa SmartAssistant) HttpAddress() string
type SmartCloud ¶
type SmartCloud struct { Domain string `json:"domain" yaml:"domain"` TLS bool `json:"tls" yaml:"tls"` GRPCPort int `json:"grpc_port" yaml:"grpc_port"` DataCenterID int `json:"data_center_id"` WorkerID int `json:"worker_id"` }
func (SmartCloud) URL ¶
func (sc SmartCloud) URL() string
func (SmartCloud) WebsocketURL ¶
func (sc SmartCloud) WebsocketURL() string
Click to show internal directories.
Click to hide internal directories.