Documentation ¶
Index ¶
- Variables
- func CreateCRDObject(s string) (*apiextensionsv1.CustomResourceDefinition, error)
- func EnsureCRDCreated(cfg *rest.Config) (created bool, err error)
- func EnsureCRDCreatedWithConfig(config *rest.Config, crd *apiextensionsv1.CustomResourceDefinition) (created bool, err error)
- func ResolveVersion(hr *appv1.HelmRequest) string
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // AutoResolveVersionOnce is intend to indicate captain that once it resolve a latest version for this HelmRequest, // in the following updates, skip auto-resolve the version again. AutoResolveVersionOnce = "auto-resolve-version-once" )
Functions ¶
func CreateCRDObject ¶ added in v1.4.0
func CreateCRDObject(s string) (*apiextensionsv1.CustomResourceDefinition, error)
CreateCRDObject create a crd object from yaml string
func EnsureCRDCreated ¶
EnsureCRDCreated tries to create/update CRD, returns (true, nil) if succeeding, otherwise returns (false, nil). 'err' should always be nil, because it is used by wait.PollUntil(), and it will exit if it is not nil.
func EnsureCRDCreatedWithConfig ¶ added in v1.4.0
func EnsureCRDCreatedWithConfig(config *rest.Config, crd *apiextensionsv1.CustomResourceDefinition) (created bool, err error)
EnsureCRDCreatedWithConfig tries to create/update crd, returns (true, nil) if succeeding, otherwise returns (false, nil). 'err' should always be nil, because it is used by wait.PollUntil(), and it will exit if it is not nil.
func ResolveVersion ¶ added in v1.3.1
func ResolveVersion(hr *appv1.HelmRequest) string
ResolveVersion resolve helmrequest version for install.
- If hr.spec.version is not empty, use it
- If hr.spec.version is empty a. If annotations.auto-resolve-version-once=false, auto resolve version every time from chartrepo b. If annotations.auto-resolve-version-once=true, auto resolve version in the first time, then use the version from .status.verion
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.