Kubernetes icon

Kubernetes

Interact with Kubernetes

Jobs → Restart

AI-generated

Overview

This node interacts with Kubernetes clusters to perform various operations on Kubernetes resources. Specifically, the 'Restart' operation restarts a specified Kubernetes resource, such as a Job, within a given namespace. This is useful for scenarios where you need to programmatically restart jobs to rerun tasks or recover from failures. For example, restarting a Kubernetes Job to trigger a new execution cycle without manually accessing the cluster.

Use Case Examples

  1. Restarting a Kubernetes Job named 'data-processing-job' in the 'default' namespace to rerun a batch processing task.
  2. Restarting a Job in a specific namespace to recover from a failed execution.

Properties

Name Meaning
Image The container image associated with the resource, used in operations like run, restart, exec, and patch.
Namespace The Kubernetes namespace where the resource (Job) is located.
Resource Name The name of the Kubernetes resource (Job) to restart.

Output

JSON

  • json - The JSON response from the Kubernetes API after restarting the resource, typically containing status or confirmation details.

Dependencies

  • Requires Kubernetes API credentials to authenticate and interact with the cluster.

Troubleshooting

  • Ensure that the Kubernetes credentials provided are valid and have sufficient permissions to restart the specified resource.
  • Verify that the resource name and namespace are correctly specified; missing or incorrect values will cause errors.
  • Common error: 'Resource name is required for restart operation!' indicates that the resourceName parameter was not provided; ensure it is set.

Links

Discussion