config

package
v0.0.0-...-f05ad83 Latest Latest
Warning

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

Go to latest
Published: Feb 17, 2019 License: Apache-2.0 Imports: 5 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrPortsUnavailable is returned when no ports can be found.
	ErrPortsUnavailable = errors.New("unable to allocate ports")
)

Functions

This section is empty.

Types

type Config

type Config struct {
	RootDir        string
	Ports          *PortMapper
	ChainID        string
	PublishNetwork bool
}

Config represents the node configuration.

func (*Config) CLIDir

func (c *Config) CLIDir() string

CLIDir returns the CLI directory within the project state.

func (*Config) ConfigDir

func (c *Config) ConfigDir() string

ConfigDir returns the config directory within the project state.

func (*Config) ConfigPath

func (c *Config) ConfigPath() string

ConfigPath returns the path of the configuration file.

func (*Config) DataDir

func (c *Config) DataDir() string

DataDir returns the data directory within the project state.

func (*Config) GenesisPath

func (c *Config) GenesisPath() string

GenesisPath returns the genesis path for the project.

func (*Config) IPFSDir

func (c *Config) IPFSDir() string

IPFSDir returns the IPFS data directory within the project state.

func (*Config) LogFile

func (c *Config) LogFile() string

LogFile returns the log file path

func (*Config) ManifestPath

func (c *Config) ManifestPath() string

ManifestPath returns the manifest file.

func (*Config) StateDir

func (c *Config) StateDir() string

StateDir returns the state directory within the project.

type PortMapper

type PortMapper struct {
	Explorer      int
	TendermintRPC int
	TendermintP2P int
	IPFS          int
}

PortMapper holds port configuration.

func AllocatePorts

func AllocatePorts() (*PortMapper, error)

AllocatePorts will allocate a set of ports

Jump to

Keyboard shortcuts

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