config

package
v1.1.8 Latest Latest
Warning

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

Go to latest
Published: Jan 27, 2021 License: AGPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type API

type API struct {
	ListeningPort uint64 `json:"listening_port"`
	AccessToken   string `json:"access_token"`
	IsReleaseMode bool   `json:"is_release_mode"`
}

type Config

type Config struct {
	NetworkID        uint64             `json:"network_id"`
	MySQLConfig      common.MySQLConfig `json:"mysql"`
	CheckFreqMinutes uint64             `json:"check_frequency_minutes"`
	Policy           Policy             `json:"policy"`
	Nodes            []Node             `json:"seeds"`
	API              API                `json:"api"`
}

func NewConfig

func NewConfig() *Config

func NewConfigWithPath

func NewConfigWithPath(path string) *Config

type Node

type Node struct {
	XPub      *chainkd.XPub `json:"xpub"`
	PublicKey string        `json:"public_key"`
	IP        string        `json:"ip"`
	Port      uint16        `json:"port"`
}

type Policy

type Policy struct {
	Confirmations uint64 `json:"confirmations"`
	RequiredRttMS uint64 `json:"required_rtt_ms"`
}

Jump to

Keyboard shortcuts

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