Documentation ¶
Index ¶
- Variables
- func ValidateDeploymentGroup(gspec dtypes.GroupSpec) error
- func ValidateDeploymentGroups(gspecs []dtypes.GroupSpec) error
- func ValidateManifest(m manifest.Manifest) error
- func ValidateManifestWithDeployment(m *manifest.Manifest, dgroups []dtypes.Group) error
- func ValidateManifestWithGroupSpecs(m *manifest.Manifest, gspecs []*dtypes.GroupSpec) error
- func ValidateResourceList(rlist types.ResourceGroup) error
- type ValConfig
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNoGroupsPresent = errors.New("validation: no groups present") ErrGroupEmptyName = errors.New("validation: group has empty name") )
Functions ¶
func ValidateDeploymentGroup ¶ added in v0.3.1
ValidateDeploymentGroup does validation for provided deployment group
func ValidateDeploymentGroups ¶
ValidateDeploymentGroups does validation for all deployment groups
func ValidateManifest ¶
ValidateManifest does validation for manifest
func ValidateManifestWithDeployment ¶
ValidateManifestWithDeployment does basic validation and returns nil
func ValidateManifestWithGroupSpecs ¶
ValidateManifestWithGroupSpecs does validation for manifest with group specifications
func ValidateResourceList ¶ added in v0.3.1
func ValidateResourceList(rlist types.ResourceGroup) error
ValidateResourceList does basic validation for resources list
Types ¶
type ValConfig ¶ added in v0.6.5
type ValConfig struct { MaxUnitCPU uint `env:"AKASH_MAX_UNIT_CPU" envDefault:"500"` MaxUnitMemory uint `env:"AKASH_MAX_UNIT_MEMORY" envDefault:"1073741824"` // 1Gi MaxUnitStorage uint `env:"AKASH_MAX_UNIT_STORAGE" envDefault:"1073741824"` // 1Gi MaxUnitCount uint `env:"AKASH_MAX_UNIT_COUNT" envDefault:"10"` MaxUnitPrice uint `env:"AKASH_MAX_UNIT_PRICE" envDefault:"10000"` MinUnitCPU uint `env:"AKASH_MIN_UNIT_CPU" envDefault:"10"` MinUnitMemory uint `env:"AKASH_MIN_UNIT_MEMORY" envDefault:"1024"` // 1Mi MinUnitStorage uint `env:"AKASH_MIN_UNIT_STORAGE" envDefault:"1024"` // 1Mi MinUnitCount uint `env:"AKASH_MIN_UNIT_COUNT" envDefault:"1"` MinUnitPrice uint `env:"AKASH_MIN_UNIT_PRICE" envDefault:"1"` MaxGroupCount int `env:"AKASH_MAX_GROUP_COUNT" envDefault:"10"` MaxGroupUnits int `env:"AKASH_MAX_GROUP_UNITS" envDefault:"10"` MaxGroupCPU int64 `env:"AKASH_MAX_GROUP_CPU" envDefault:"1000"` MaxGroupMemory int64 `env:"AKASH_MAX_GROUP_MEMORY" envDefault:"1073741824"` // 1Gi MaxGroupStorage int64 `env:"AKASH_MAX_GROUP_STORAGE" envDefault:"5368709120"` // 5Gi MinGroupMemPrice int64 `env:"AKASH_MEM_PRICE_MIN" envDefault:"50"` MaxGroupMemPrice int64 `env:"AKASH_MEM_PRICE_MAX" envDefault:"1048576"` }
ValConfig represents validation config
Click to show internal directories.
Click to hide internal directories.