config

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Jun 29, 2021 License: AGPL-3.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrFailedToLoadConfiguration = errors.New("failed to load Spire's configuration")
View Source
var ErrFailedToParsePrivKeySeed = errors.New("failed to parse the privKeySeed field")
View Source
var ErrFailedToReadPassphraseFile = errors.New("failed to read the ethereum password file")

Functions

This section is empty.

Types

type Config

type Config struct {
	Ethereum Ethereum `json:"ethereum"`
	P2P      P2P      `json:"p2p"`
	RPC      RPC      `json:"rpc"`
	Feeds    []string `json:"feeds"`
	Pairs    []string `json:"pairs"`
}

func (*Config) ConfigureAgent

func (c *Config) ConfigureAgent(deps Dependencies) (*spire.Agent, error)

func (*Config) ConfigureSpire

func (c *Config) ConfigureSpire(deps Dependencies) (*spire.Spire, error)

type Dependencies

type Dependencies struct {
	Context context.Context
	Logger  log.Logger
}

type Ethereum

type Ethereum struct {
	From     string `json:"from"`
	Keystore string `json:"keystore"`
	Password string `json:"password"`
}

type P2P

type P2P struct {
	PrivKeySeed      string   `json:"privKeySeed"`
	ListenAddrs      []string `json:"listenAddrs"`
	BootstrapAddrs   []string `json:"bootstrapAddrs"`
	DirectPeersAddrs []string `json:"directPeersAddrs"`
	BlockedAddrs     []string `json:"blockedAddrs"`
	DisableDiscovery bool     `json:"disableDiscovery"`
}

type RPC

type RPC struct {
	Address string `json:"address"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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