Documentation
¶
Index ¶
- Constants
- type REST
- func (r *REST) ConvertApplicationToHelmRelease(app *appsv1alpha1.Application) (*helmv2.HelmRelease, error)
- func (r *REST) ConvertHelmReleaseToApplication(hr *unstructured.Unstructured) (appsv1alpha1.Application, error)
- func (r *REST) ConvertToTable(ctx context.Context, object runtime.Object, tableOptions runtime.Object) (*metav1.Table, error)
- func (r *REST) Create(ctx context.Context, obj runtime.Object, ...) (runtime.Object, error)
- func (r *REST) Delete(ctx context.Context, name string, deleteValidation rest.ValidateObjectFunc, ...) (runtime.Object, bool, error)
- func (r *REST) Destroy()
- func (r *REST) Get(ctx context.Context, name string, options *metav1.GetOptions) (runtime.Object, error)
- func (r *REST) GetSingularName() string
- func (r *REST) GroupVersionKind(schema.GroupVersion) schema.GroupVersionKind
- func (r *REST) Kind() string
- func (r *REST) List(ctx context.Context, options *metainternalversion.ListOptions) (runtime.Object, error)
- func (r *REST) NamespaceScoped() bool
- func (r *REST) New() runtime.Object
- func (r *REST) NewList() runtime.Object
- func (r *REST) Update(ctx context.Context, name string, objInfo rest.UpdatedObjectInfo, ...) (runtime.Object, bool, error)
- func (r *REST) Watch(ctx context.Context, options *metainternalversion.ListOptions) (watch.Interface, error)
Constants ¶
const ( LabelPrefix = "apps.cozystack.io-" AnnotationPrefix = "apps.cozystack.io-" )
Define constants for label and annotation prefixes
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type REST ¶
type REST struct {
// contains filtered or unexported fields
}
REST implements the RESTStorage interface for Application resources
func (*REST) ConvertApplicationToHelmRelease ¶
func (r *REST) ConvertApplicationToHelmRelease(app *appsv1alpha1.Application) (*helmv2.HelmRelease, error)
ConvertApplicationToHelmRelease converts an Application to a HelmRelease
func (*REST) ConvertHelmReleaseToApplication ¶
func (r *REST) ConvertHelmReleaseToApplication(hr *unstructured.Unstructured) (appsv1alpha1.Application, error)
ConvertHelmReleaseToApplication converts a HelmRelease to an Application
func (*REST) ConvertToTable ¶
func (r *REST) ConvertToTable(ctx context.Context, object runtime.Object, tableOptions runtime.Object) (*metav1.Table, error)
ConvertToTable implements the TableConvertor interface for displaying resources in a table format
func (*REST) Create ¶
func (r *REST) Create(ctx context.Context, obj runtime.Object, createValidation rest.ValidateObjectFunc, options *metav1.CreateOptions) (runtime.Object, error)
Create handles the creation of a new Application by converting it to a HelmRelease
func (*REST) Delete ¶
func (r *REST) Delete(ctx context.Context, name string, deleteValidation rest.ValidateObjectFunc, options *metav1.DeleteOptions) (runtime.Object, bool, error)
Delete removes an Application by deleting the corresponding HelmRelease
func (*REST) Get ¶
func (r *REST) Get(ctx context.Context, name string, options *metav1.GetOptions) (runtime.Object, error)
Get retrieves an Application by converting the corresponding HelmRelease
func (*REST) GetSingularName ¶
GetSingularName returns the singular name of the resource
func (*REST) GroupVersionKind ¶
func (r *REST) GroupVersionKind(schema.GroupVersion) schema.GroupVersionKind
GroupVersionKind returns the GroupVersionKind for REST
func (*REST) List ¶
func (r *REST) List(ctx context.Context, options *metainternalversion.ListOptions) (runtime.Object, error)
List retrieves a list of Applications by converting HelmReleases
func (*REST) NamespaceScoped ¶
NamespaceScoped indicates whether the resource is namespaced
func (*REST) Update ¶
func (r *REST) Update(ctx context.Context, name string, objInfo rest.UpdatedObjectInfo, createValidation rest.ValidateObjectFunc, updateValidation rest.ValidateObjectUpdateFunc, forceAllowCreate bool, options *metav1.UpdateOptions) (runtime.Object, bool, error)
Update updates an existing Application by converting it to a HelmRelease
func (*REST) Watch ¶
func (r *REST) Watch(ctx context.Context, options *metainternalversion.ListOptions) (watch.Interface, error)
Watch sets up a watch on HelmReleases, filters them based on sourceRef and prefix, and converts events to Applications