Files
diun/internal/model/providers.go
2019-12-14 03:55:58 +01:00

33 lines
1.4 KiB
Go

package model
// Providers represents a provider configuration
type Providers struct {
Docker []PrdDocker `yaml:"docker,omitempty" json:",omitempty"`
Swarm []PrdSwarm `yaml:"swarm,omitempty" json:",omitempty"`
Image []PrdImage `yaml:"image,omitempty" json:",omitempty"`
}
// PrdDocker holds docker provider configuration
type PrdDocker struct {
ID string `yaml:"id,omitempty" json:",omitempty"`
Endpoint string `yaml:"endpoint,omitempty" json:",omitempty"`
ApiVersion string `yaml:"api_version,omitempty" json:",omitempty"`
TLSCertsPath string `yaml:"tls_certs_path,omitempty" json:",omitempty"`
TLSVerify bool `yaml:"tls_verify,omitempty" json:",omitempty"`
WatchByDefault bool `yaml:"watch_by_default,omitempty" json:",omitempty"`
WatchStopped bool `yaml:"watch_stopped,omitempty" json:",omitempty"`
}
// PrdSwarm holds swarm provider configuration
type PrdSwarm struct {
ID string `yaml:"id,omitempty" json:",omitempty"`
Endpoint string `yaml:"endpoint,omitempty" json:",omitempty"`
ApiVersion string `yaml:"api_version,omitempty" json:",omitempty"`
TLSCertsPath string `yaml:"tls_certs_path,omitempty" json:",omitempty"`
TLSVerify bool `yaml:"tls_verify,omitempty" json:",omitempty"`
WatchByDefault bool `yaml:"watch_by_default,omitempty" json:",omitempty"`
}
// PrdImage holds image provider configuration
type PrdImage Image