traefik/pkg/provider/kv/etcd/etcd.go

26 lines
558 B
Go
Raw Normal View History

package etcd
import (
"github.com/abronan/valkeyrie/store"
"github.com/traefik/traefik/v2/pkg/provider"
"github.com/traefik/traefik/v2/pkg/provider/kv"
)
var _ provider.Provider = (*Provider)(nil)
// Provider holds configurations of the provider.
type Provider struct {
2020-10-30 11:44:05 +00:00
kv.Provider `export:"true"`
}
// SetDefaults sets the default values.
func (p *Provider) SetDefaults() {
p.Provider.SetDefaults()
p.Endpoints = []string{"127.0.0.1:2379"}
}
2020-05-11 10:06:07 +00:00
// Init the provider.
func (p *Provider) Init() error {
return p.Provider.Init(store.ETCDV3, "etcd")
}