config

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	DefaultConfig = Config{}
)

Functions

func LoadCubeInputs

func LoadCubeInputs(path string) (cubeInputs map[string]*CubeInput, err error)

Types

type Config

type Config struct {
	ConfigInputs *ConfigInputs `config:"config.inputs"`
}

type ConfigInputs

type ConfigInputs struct {
	Path   string `config:"path"`
	Reload Reload `config:"reload"`
}

type CubeInput

type CubeInput struct {
	Name           string        `config:"name"`
	Enabled        bool          `config:"enabled"`
	Period         time.Duration `config:"period"`
	PolycubeAPIURL string        `config:"polycube.api-url"`
	Done           bool
	Reload         *CubeInput
	Req            *http.Request
	Ticker         *time.Ticker
}

type Reload

type Reload struct {
	Enabled bool          `config:"enabled"`
	Period  time.Duration `config:"period"`
}

Jump to

Keyboard shortcuts

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