Classes
class

pytest_helm_charts.flux.utils.NamespacedFluxCR(api, obj)

Bases
pykube.objects.NamespacedAPIObject pykube.objects.APIObject

Baseclass for all Kubernetes API objects

Parameters
  • api (HTTPClient)
  • obj (dict)
Attributes
  • _original_obj
  • annotations (dict) Annotations of the Kubernetes resource (metadata.annotations)
    Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations</>
  • api
  • labels (dict) Labels of the Kubernetes resource (metadata.labels)
    Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels</>
  • name (str) Name of the Kubernetes resource (metadata.name)
    Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names</>
  • namespace (str) Namespace scope of the Kubernetes resource (metadata.namespace)
    Namespace defines the space within each name must be unique. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces</>
  • obj
Methods
  • delete(propagation_policy) Delete the Kubernetes resource by calling the API.</>
  • patch(strategic_merge_patch, subresource) Patch the Kubernetes resource by calling the API with a "strategic merge" patch.</>
  • update(is_strategic, subresource) Update the Kubernetes resource by calling the API (patch)</>
method

patch(strategic_merge_patch, subresource=None)

Patch the Kubernetes resource by calling the API with a "strategic merge" patch.

Parameters
  • strategic_merge_patch
  • subresource (optional)
method

update(is_strategic=True, subresource=None)

Update the Kubernetes resource by calling the API (patch)

Parameters
  • is_strategic (optional)
  • subresource (optional)
method

delete(propagation_policy=None)

Delete the Kubernetes resource by calling the API.

The parameter propagation_policy defines whether to cascade the delete. It can be "Foreground", "Background" or "Orphan". See https://kubernetes.io/docs/concepts/workloads/controllers/garbage-collection/#setting-the-cascading-deletion-policy

Parameters
  • propagation_policy (str, optional)