Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var AppResourceTypes = []ResourceType{ NewResourceType(app.Size_SIZE_NANO, "0.1", "256Mi"), NewResourceType(app.Size_SIZE_MIRCO, "0.25", "512Mi"), NewResourceType(app.Size_SIZE_MINI, "0.5", "1Gi"), NewResourceType(app.Size_SIZE_SMALL, "1", "2Gi"), NewResourceType(app.Size_SIZE_MEDIUM, "2", "4Gi"), NewResourceType(app.Size_SIZE_LARGE, "4", "8Gi"), NewResourceType(app.Size_SIZE_XLARGE, "8", "16Gi"), }
Functions ¶
func BuildResources ¶
func BuildResources(size app.Size, oversoldRate float64) v1.ResourceRequirements
Types ¶
type ResourceType ¶
type ResourceType struct { Name app.Size `json:"name"` Label string `json:"label"` LimitsCPU resource.Quantity `json:"-"` LimitsMem resource.Quantity `json:"-"` }
func AppResourceTypeGet ¶
func AppResourceTypeGet(name app.Size) ResourceType
func NewResourceType ¶
func NewResourceType(name app.Size, cpu, mem string) ResourceType
func (*ResourceType) RequestsCPU ¶
func (rt *ResourceType) RequestsCPU(oversoldRate float64) resource.Quantity
func (*ResourceType) RequestsMem ¶
func (rt *ResourceType) RequestsMem(oversoldRate float64) resource.Quantity
Click to show internal directories.
Click to hide internal directories.