base

package
v1.0.3 Latest Latest
Warning

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

Go to latest
Published: Sep 22, 2017 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const (
	LocalConsulAddress = "localhost:8500"
	LocalNomadAddress  = "http://localhost:4646"
)

Define default local addresses for Consul and Nomad

Variables

This section is empty.

Functions

func DefaultConfig

func DefaultConfig() *structs.Config

DefaultConfig returns a default configuration struct with sane defaults.

func DevConfig

func DevConfig() *structs.Config

DevConfig returns a configuration struct with sane defaults for development and testing purposes.

func InitializeClients

func InitializeClients(config *structs.Config) (err error)

InitializeClients completes the setup process for the Nomad and Consul clients. Must be called after configuration merging is complete.

func LoadConfig

func LoadConfig(path string) (*structs.Config, error)

LoadConfig loads the configuration at the given path whether the specified path is an individual file or a directory of numerous configuration files.

func LoadConfigDir

func LoadConfigDir(dir string) (*structs.Config, error)

LoadConfigDir loads all the configurations in the given directory in lexicographic order.

func ParseConfig

func ParseConfig(r io.Reader) (*structs.Config, error)

ParseConfig parses the config from the given io.Reader.

func ParseConfigFile

func ParseConfigFile(path string) (*structs.Config, error)

ParseConfigFile parses the given path as a config file.

Types

This section is empty.

Jump to

Keyboard shortcuts

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