Kubernetes icon

Kubernetes

Interact with Kubernetes

StatefulSets → Patch

AI-generated

Overview

This node interacts with Kubernetes clusters to perform various operations on Kubernetes resources, specifically supporting the 'Patch' operation for StatefulSets in this context. It allows users to modify existing StatefulSets by applying JSON patch data, which can be used to update configurations, labels, or other resource specifications without recreating the resource. This is useful for dynamically adjusting StatefulSets in a Kubernetes environment, such as updating container images, resource limits, or other settings.

Use Case Examples

  1. Updating the image version of a StatefulSet by patching the container image field.
  2. Modifying the number of replicas or resource limits of a StatefulSet using patch data.
  3. Applying configuration changes to a StatefulSet without downtime by patching its spec.

Properties

Name Meaning
Image The container image to use, relevant for operations like run, restart, exec, and patch.
Namespace The Kubernetes namespace where the StatefulSet resource resides.
Resource Name The name of the StatefulSet resource to patch.
Patch Data The JSON patch data to apply to the StatefulSet resource, specifying the changes to be made.

Output

JSON

  • json - The JSON response from the Kubernetes API after applying the patch to the StatefulSet resource.

Dependencies

  • Requires Kubernetes API credentials for authentication and interaction with the Kubernetes cluster.

Troubleshooting

  • Ensure that the 'Resource Name' is provided; otherwise, the node will throw an error indicating the resource name is required for the patch operation.
  • Patch data must be valid JSON; invalid JSON will cause errors when parsing or applying the patch.
  • Kubernetes API credentials must be correctly configured and valid to avoid authentication errors.
  • The node throws an error if the specified operation is not implemented or supported.

Discussion