defaults

package
v0.7.2 Latest Latest
Warning

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

Go to latest
Published: May 23, 2024 License: MPL-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	NATS = common.ContainerSpec{
		Resources: &v1.ResourceRequirements{
			Requests: v1.ResourceList{
				"memory": resource.MustParse("64Mi"),
				"cpu":    resource.MustParse("100m"),
			},
			Limits: v1.ResourceList{
				"memory": resource.MustParse("128Mi"),
				"cpu":    resource.MustParse("2"),
			},
		},
		LivenessProbe: &v1.Probe{
			ProbeHandler: v1.ProbeHandler{
				HTTPGet: &v1.HTTPGetAction{
					Path: "/healthz?js-enabled-only=true",
					Port: intstr.FromString("monitor"),
				},
			},
			TimeoutSeconds:   3,
			PeriodSeconds:    30,
			FailureThreshold: 3,
		},
		ReadinessProbe: &v1.Probe{
			ProbeHandler: v1.ProbeHandler{
				HTTPGet: &v1.HTTPGetAction{
					Path: "/healthz?js-enabled-only=true",
					Port: intstr.FromString("monitor"),
				},
			},
			TimeoutSeconds:   3,
			PeriodSeconds:    10,
			FailureThreshold: 3,
		},
		StartupProbe: &v1.Probe{
			ProbeHandler: v1.ProbeHandler{
				HTTPGet: &v1.HTTPGetAction{
					Path: "/healthz",
					Port: intstr.FromString("monitor"),
				},
			},
			PeriodSeconds:    5,
			FailureThreshold: 90,
		},
	}

	Broker = common.ContainerSpec{
		Resources: &v1.ResourceRequirements{
			Requests: v1.ResourceList{
				"memory": resource.MustParse("64Mi"),
				"cpu":    resource.MustParse("100m"),
			},
			Limits: v1.ResourceList{
				"memory": resource.MustParse("256Mi"),
				"cpu":    resource.MustParse("2"),
			},
		},
		LivenessProbe: &v1.Probe{
			ProbeHandler: v1.ProbeHandler{
				HTTPGet: &v1.HTTPGetAction{
					Port: intstr.FromString("health"),
				},
			},
		},
		ReadinessProbe: &v1.Probe{
			ProbeHandler: v1.ProbeHandler{
				HTTPGet: &v1.HTTPGetAction{
					Port: intstr.FromString("health"),
				},
			},
		},
	}

	HTTPSrv = common.ContainerSpec{
		Resources: &v1.ResourceRequirements{
			Requests: v1.ResourceList{
				"memory": resource.MustParse("64Mi"),
				"cpu":    resource.MustParse("100m"),
			},
			Limits: v1.ResourceList{
				"memory": resource.MustParse("160Mi"),
				"cpu":    resource.MustParse("2"),
			},
		},
		LivenessProbe: &v1.Probe{
			ProbeHandler: v1.ProbeHandler{
				HTTPGet: &v1.HTTPGetAction{
					Port: intstr.FromString("health"),
				},
			},
		},
		ReadinessProbe: &v1.Probe{
			ProbeHandler: v1.ProbeHandler{
				HTTPGet: &v1.HTTPGetAction{
					Port: intstr.FromString("health"),
				},
			},
		},
	}

	Component = common.ContainerSpec{
		Resources: &v1.ResourceRequirements{
			Requests: v1.ResourceList{},
			Limits:   v1.ResourceList{},
		},
		LivenessProbe: &v1.Probe{
			ProbeHandler: v1.ProbeHandler{
				HTTPGet: &v1.HTTPGetAction{
					Port: intstr.FromString("health"),
				},
			},
		},
		ReadinessProbe: &v1.Probe{
			ProbeHandler: v1.ProbeHandler{
				HTTPGet: &v1.HTTPGetAction{
					Port: intstr.FromString("health"),
				},
			},
		},
	}
)

Functions

func Set

func Set(cur *common.ContainerSpec, defs *common.ContainerSpec)

Types

This section is empty.

Jump to

Keyboard shortcuts

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