configuration

package
v3.9.0-alpha.1+incompa... Latest Latest
Warning

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

Go to latest
Published: Dec 20, 2017 License: Apache-2.0 Imports: 13 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// CurrentVersion is the most recent Version that can be parsed.
	CurrentVersion = configuration.MajorMinorVersion(1, 0)

	ErrUnsupportedVersion = errors.New("Unsupported openshift configuration version")
)

Functions

func InitExtraConfig

func InitExtraConfig(dockercfg *configuration.Configuration, cfg *Configuration) error

func TokenRealm

func TokenRealm(tokenRealmString string) (*url.URL, error)

TokenRealm returns the template URL to use as the token realm redirect. An empty scheme/host in the returned URL means to match the scheme/host on incoming requests.

Types

type Audit

type Audit struct {
	Enabled bool `yaml:"enabled"`
}

type Auth

type Auth struct {
	Realm      string `yaml:"realm"`
	TokenRealm string `yaml:"tokenrealm"`
}

type Cache

type Cache struct {
	BlobRepositoryTTL time.Duration `yaml:"blobrepositoryttl"`
}

type Compatibility

type Compatibility struct {
	AcceptSchema2 bool `yaml:"acceptschema2"`
}

type Configuration

type Configuration struct {
	Version       configuration.Version `yaml:"version"`
	Metrics       Metrics               `yaml:"metrics"`
	Requests      Requests              `yaml:"requests"`
	KubeConfig    string                `yaml:"kubeconfig"`
	Server        *Server               `yaml:"server"`
	Auth          *Auth                 `yaml:"auth"`
	Audit         *Audit                `yaml:"audit"`
	Cache         *Cache                `yaml:"cache"`
	Quota         *Quota                `yaml:"quota"`
	Pullthrough   *Pullthrough          `yaml:"pullthrough"`
	Compatibility *Compatibility        `yaml:"compatibility"`
}

func Parse

Parse parses an input configuration and returns docker configuration structure and openshift specific configuration. Environment variables may be used to override configuration parameters.

type Metrics

type Metrics struct {
	Enabled bool   `yaml:"enabled"`
	Secret  string `yaml:"secret"`
}

type Pullthrough

type Pullthrough struct {
	Enabled bool `yaml:"enabled"`
	Mirror  bool `yaml:"mirror"`
}

type Quota

type Quota struct {
	Enabled  bool          `yaml:"enabled"`
	CacheTTL time.Duration `yaml:"cachettl"`
}

type Requests

type Requests struct {
	Read  RequestsLimits `yaml:"read"`
	Write RequestsLimits `yaml:"write"`
}

type RequestsLimits

type RequestsLimits struct {
	MaxRunning     int           `yaml:"maxrunning"`
	MaxInQueue     int           `yaml:"maxinqueue"`
	MaxWaitInQueue time.Duration `yaml:"maxwaitinqueue"`
}

type Server

type Server struct {
	Addr string `yaml:"addr"`
}

Jump to

Keyboard shortcuts

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