flags

package
v1.13.0 Latest Latest
Warning

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

Go to latest
Published: Jan 17, 2017 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// DefaultTrustKeyFile is the default filename for the trust key
	DefaultTrustKeyFile = "key.json"
	// DefaultCaFile is the default filename for the CA pem file
	DefaultCaFile = "ca.pem"
	// DefaultKeyFile is the default filename for the key pem file
	DefaultKeyFile = "key.pem"
	// DefaultCertFile is the default filename for the cert pem file
	DefaultCertFile = "cert.pem"
	// FlagTLSVerify is the flag name for the tls verification option
	FlagTLSVerify = "tlsverify"
)

Variables

This section is empty.

Functions

func SetLogLevel added in v1.13.0

func SetLogLevel(logLevel string)

SetLogLevel sets the logrus logging level

Types

type ClientOptions added in v1.13.0

type ClientOptions struct {
	Common    *CommonOptions
	ConfigDir string
	Version   bool
}

ClientOptions are the options used to configure the client cli

func NewClientOptions added in v1.13.0

func NewClientOptions() *ClientOptions

NewClientOptions returns a new ClientOptions

type CommonOptions added in v1.13.0

type CommonOptions struct {
	Debug      bool
	Hosts      []string
	LogLevel   string
	TLS        bool
	TLSVerify  bool
	TLSOptions *tlsconfig.Options
	TrustKey   string
}

CommonOptions are options common to both the client and the daemon.

func NewCommonOptions added in v1.13.0

func NewCommonOptions() *CommonOptions

NewCommonOptions returns a new CommonOptions

func (*CommonOptions) InstallFlags added in v1.13.0

func (commonOpts *CommonOptions) InstallFlags(flags *pflag.FlagSet)

InstallFlags adds flags for the common options on the FlagSet

func (*CommonOptions) SetDefaultOptions added in v1.13.0

func (commonOpts *CommonOptions) SetDefaultOptions(flags *pflag.FlagSet)

SetDefaultOptions sets default values for options after flag parsing is complete

Jump to

Keyboard shortcuts

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