provider

package
v1.0.0-beta.809 Latest Latest
Warning

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

Go to latest
Published: May 30, 2016 License: MIT Imports: 41 Imported by: 0

Documentation

Overview

Package provider holds the different provider implementation.

Index

Constants

View Source
const (
	// DefaultWatchWaitTime is the duration to wait when polling consul
	DefaultWatchWaitTime = 15 * time.Second
	// DefaultConsulCatalogTagPrefix is a prefix for additional service/node configurations
	DefaultConsulCatalogTagPrefix = "traefik"
)
View Source
const DockerAPIVersion string = "1.21"

DockerAPIVersion is a constant holding the version of the Docker API traefik will use

Variables

This section is empty.

Functions

This section is empty.

Types

type BaseProvider

type BaseProvider struct {
	Watch    bool   `description:"Watch provider"`
	Filename string `description:"Override default configuration template. For advanced users :)"`
}

BaseProvider should be inherited by providers

type BoltDb

type BoltDb struct {
	Kv
}

BoltDb holds configurations of the BoltDb provider.

func (*BoltDb) Provide

func (provider *BoltDb) Provide(configurationChan chan<- types.ConfigMessage, pool *safe.Pool) error

Provide allows the provider to provide configurations to traefik using the given configuration channel.

type Consul

type Consul struct {
	Kv
}

Consul holds configurations of the Consul provider.

func (*Consul) Provide

func (provider *Consul) Provide(configurationChan chan<- types.ConfigMessage, pool *safe.Pool) error

Provide allows the provider to provide configurations to traefik using the given configuration channel.

type ConsulCatalog

type ConsulCatalog struct {
	BaseProvider
	Endpoint string `description:"Consul server endpoint"`
	Domain   string `description:"Default domain used"`

	Prefix string
	// contains filtered or unexported fields
}

ConsulCatalog holds configurations of the Consul catalog provider.

func (*ConsulCatalog) Provide

func (provider *ConsulCatalog) Provide(configurationChan chan<- types.ConfigMessage, pool *safe.Pool) error

Provide allows the provider to provide configurations to traefik using the given configuration channel.

type Docker

type Docker struct {
	BaseProvider
	Endpoint string     `description:"Docker server endpoint. Can be a tcp or a unix socket endpoint"`
	Domain   string     `description:"Default domain used"`
	TLS      *DockerTLS `description:"Enable Docker TLS support"`
}

Docker holds configurations of the Docker provider.

func (*Docker) Provide

func (provider *Docker) Provide(configurationChan chan<- types.ConfigMessage, pool *safe.Pool) error

Provide allows the provider to provide configurations to traefik using the given configuration channel.

type DockerTLS

type DockerTLS struct {
	CA                 string `description:"TLS CA"`
	Cert               string `description:"TLS cert"`
	Key                string `description:"TLS key"`
	InsecureSkipVerify bool   `description:"TLS insecure skip verify"`
}

DockerTLS holds TLS specific configurations

type Etcd

type Etcd struct {
	Kv
}

Etcd holds configurations of the Etcd provider.

func (*Etcd) Provide

func (provider *Etcd) Provide(configurationChan chan<- types.ConfigMessage, pool *safe.Pool) error

Provide allows the provider to provide configurations to traefik using the given configuration channel.

type File

type File struct {
	BaseProvider
}

File holds configurations of the File provider.

func (*File) Provide

func (provider *File) Provide(configurationChan chan<- types.ConfigMessage, pool *safe.Pool) error

Provide allows the provider to provide configurations to traefik using the given configuration channel.

type Kubernetes

type Kubernetes struct {
	BaseProvider
	Endpoint               string     `description:"Kubernetes server endpoint"`
	DisablePassHostHeaders bool       `description:"Kubernetes disable PassHost Headers"`
	Namespaces             Namespaces `description:"Kubernetes namespaces"`
}

Kubernetes holds configurations of the Kubernetes provider.

func (*Kubernetes) Provide

func (provider *Kubernetes) Provide(configurationChan chan<- types.ConfigMessage, pool *safe.Pool) error

Provide allows the provider to provide configurations to traefik using the given configuration channel.

type Kv

type Kv struct {
	BaseProvider
	Endpoint string `description:"Comma sepparated server endpoints"`
	Prefix   string `description:"Prefix used for KV store"`
	TLS      *KvTLS `description:"Enable TLS support"`
	// contains filtered or unexported fields
}

Kv holds common configurations of key-value providers.

type KvTLS

type KvTLS struct {
	CA                 string `description:"TLS CA"`
	Cert               string `description:"TLS cert"`
	Key                string `description:"TLS key"`
	InsecureSkipVerify bool   `description:"TLS insecure skip verify"`
}

KvTLS holds TLS specific configurations

type Marathon

type Marathon struct {
	BaseProvider     `mapstructure:",squash" description:"go through"`
	Endpoint         string `description:"Marathon server endpoint. You can also specify multiple endpoint for Marathon"`
	Domain           string `description:"Default domain used"`
	ExposedByDefault bool   `description:"Expose Marathon apps by default"`
	Basic            *MarathonBasic
	TLS              *tls.Config
	// contains filtered or unexported fields
}

Marathon holds configuration of the Marathon provider.

func (*Marathon) Provide

func (provider *Marathon) Provide(configurationChan chan<- types.ConfigMessage, pool *safe.Pool) error

Provide allows the provider to provide configurations to traefik using the given configuration channel.

type MarathonBasic

type MarathonBasic struct {
	HTTPBasicAuthUser string
	HTTPBasicPassword string
}

MarathonBasic holds basic authentication specific configurations

type Namespaces

type Namespaces []string

Namespaces holds kubernetes namespaces

func (*Namespaces) Get

func (ns *Namespaces) Get() interface{}

Get []string

func (*Namespaces) Set

func (ns *Namespaces) Set(str string) error

Set adds strings elem into the the parser it splits str on , and ;

func (*Namespaces) SetValue

func (ns *Namespaces) SetValue(val interface{})

SetValue sets []string into the parser

func (*Namespaces) String

func (ns *Namespaces) String() string

String return slice in a string

type Provider

type Provider interface {
	// Provide allows the provider to provide configurations to traefik
	// using the given configuration channel.
	Provide(configurationChan chan<- types.ConfigMessage, pool *safe.Pool) error
}

Provider defines methods of a provider.

type Zookepper

type Zookepper struct {
	Kv
}

Zookepper holds configurations of the Zookepper provider.

func (*Zookepper) Provide

func (provider *Zookepper) Provide(configurationChan chan<- types.ConfigMessage, pool *safe.Pool) error

Provide allows the provider to provide configurations to traefik using the given configuration channel.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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