Documentation
¶
Index ¶
- func ApplyTemplates(config v1.CanarySpec) v1.CanarySpec
- func GetClusterName(config *rest.Config) string
- func GetKubeconfig() string
- func NewK8sClient() (*kubernetes.Clientset, error)
- func ParseConfig(configfile string) v1.CanarySpec
- type Check
- type CheckResult
- type CheckStatus
- type Checker
- type Checks
- type Config
- type Endpoint
- type JSONTime
- type Metric
- type MetricType
- type StructTemplater
- type URL
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ApplyTemplates ¶
func ApplyTemplates(config v1.CanarySpec) v1.CanarySpec
func GetClusterName ¶ added in v0.11.3
func GetKubeconfig ¶
func GetKubeconfig() string
func NewK8sClient ¶
func NewK8sClient() (*kubernetes.Clientset, error)
Types ¶
type Check ¶
type Check struct { Key string `json:"key"` Type string `json:"type"` Name string `json:"name"` CanaryName string `json:"canaryName"` Description string `json:"description"` Endpoint string `json:"endpoint"` Uptime string `json:"uptime"` Latency string `json:"latency"` Statuses []CheckStatus `json:"checkStatuses" mapstructure:"-"` CheckCanary *v1.Canary `json:"-"` }
func (Check) GetDescription ¶
type CheckResult ¶
type CheckResult struct { Pass bool Invalid bool Duration int64 Description string Message string Metrics []Metric // Check is the configuration Check external.Check }
func (CheckResult) GetDescription ¶ added in v0.11.4
func (c CheckResult) GetDescription() string
func (CheckResult) String ¶
func (c CheckResult) String() string
type CheckStatus ¶ added in v0.11.0
type Checker ¶
type Checker interface {
CheckArgs(args map[string]interface{}) *CheckResult
}
type Config ¶
type Config struct { HTTP []v1.HTTPCheck `yaml:"http,omitempty" json:"http,omitempty"` DNS []v1.DNSCheck `yaml:"dns,omitempty" json:"dns,omitempty"` ContainerdPull []v1.ContainerdPullCheck `yaml:"containerdPull,omitempty" json:"containerdPull,omitempty"` ContainerdPush []v1.ContainerdPushCheck `yaml:"containerdPush,omitempty" json:"containerdPush,omitempty"` DockerPull []v1.DockerPullCheck `yaml:"docker,omitempty" json:"docker,omitempty"` DockerPush []v1.DockerPushCheck `yaml:"dockerPush,omitempty" json:"dockerPush,omitempty"` S3 []v1.S3Check `yaml:"s3,omitempty" json:"s3,omitempty"` S3Bucket []v1.S3BucketCheck `yaml:"s3Bucket,omitempty" json:"s3Bucket,omitempty"` TCP []v1.TCPCheck `yaml:"tcp,omitempty" json:"tcp,omitempty"` Pod []v1.PodCheck `yaml:"pod,omitempty" json:"pod,omitempty"` LDAP []v1.LDAPCheck `yaml:"ldap,omitempty" json:"ldap,omitempty"` SSL []v1.SSLCheck `yaml:"ssl,omitempty" json:"ssl,omitempty"` ICMP []v1.ICMPCheck `yaml:"icmp,omitempty" json:"icmp,omitempty"` Postgres []v1.PostgresCheck `yaml:"postgres,omitempty" json:"postgres,omitempty"` Helm []v1.HelmCheck `yaml:"helm,omitempty" json:"helm,omitempty"` Namespace []v1.NamespaceCheck `yaml:"namespace,omitempty" json:"namespace,omitempty"` Interval metav1.Duration `yaml:"-" json:"interval,omitempty"` }
type JSONTime ¶ added in v0.11.0
func (JSONTime) MarshalJSON ¶ added in v0.11.0
func (*JSONTime) UnmarshalJSON ¶ added in v0.11.0
type Metric ¶
type Metric struct { Name string Type MetricType Labels map[string]string Value float64 }
type MetricType ¶
type MetricType string
type StructTemplater ¶ added in v0.11.0
func (StructTemplater) Struct ¶ added in v0.11.0
func (w StructTemplater) Struct(reflect.Value) error
this func is required to fulfil the reflectwalk.StructWalker interface
func (StructTemplater) StructField ¶ added in v0.11.0
func (w StructTemplater) StructField(f reflect.StructField, v reflect.Value) error
func (StructTemplater) Template ¶ added in v0.11.0
func (w StructTemplater) Template(val string) string
Click to show internal directories.
Click to hide internal directories.