config

package
Version: v0.0.0-...-831ebea Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2020 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ConfigFileName is the name of config file
	ConfigFileName = "config.json"
)

Variables

This section is empty.

Functions

func ContextStoreDir

func ContextStoreDir() string

ContextStoreDir returns the directory the docker contexts are stored in

func Dir

func Dir() string

Dir returns the directory the configuration file is stored in

func LegacyLoadFromReader

func LegacyLoadFromReader(configData io.Reader) (*configfile.ConfigFile, error)

LegacyLoadFromReader is a convenience function that creates a ConfigFile object from a non-nested reader

func Load

func Load(configDir string) (*configfile.ConfigFile, error)

Load reads the configuration files in the given directory, and sets up the auth config information and returns values. FIXME: use the internal golang config parser

func LoadDefaultConfigFile

func LoadDefaultConfigFile(stderr io.Writer) *configfile.ConfigFile

LoadDefaultConfigFile attempts to load the default config file and returns an initialized ConfigFile struct if none is found.

func LoadFromReader

func LoadFromReader(configData io.Reader) (*configfile.ConfigFile, error)

LoadFromReader is a convenience function that creates a ConfigFile object from a reader

func Path

func Path(p ...string) (string, error)

Path returns the path to a file relative to the config dir

func SetDir

func SetDir(dir string)

SetDir sets the directory the configuration file is stored in

Types

This section is empty.

Source Files

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL