configs

package
v0.5.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 28, 2022 License: BSD-3-Clause Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type APIConfig

type APIConfig struct {
	RPC struct {
		Endpoints     []string `yaml:"endpoints"`
		DisableUpdate bool     `yaml:"disableUpdate"`
	} `yaml:"rpc"`
	NodeId string `yaml:"nodeId"`
	Secret string `yaml:"secret"`
}

APIConfig 节点API配置

func LoadAPIConfig

func LoadAPIConfig() (*APIConfig, error)

func (*APIConfig) WriteFile

func (this *APIConfig) WriteFile(path string) error

WriteFile 保存到文件

type ClusterConfig

type ClusterConfig struct {
	RPC struct {
		Endpoints     []string `yaml:"endpoints"`
		DisableUpdate bool     `yaml:"disableUpdate"`
	} `yaml:"rpc"`
	ClusterId string `yaml:"clusterId"`
	Secret    string `yaml:"secret"`
}

ClusterConfig 集群配置

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL