Kubernetes icon

Kubernetes

Interact with Kubernetes

CronJobs → Delete

AI-generated

Overview

This node interacts with Kubernetes to perform various operations on Kubernetes resources. Specifically, for the 'CronJobs' resource with the 'Delete' operation, it deletes a specified CronJob in a given namespace. This is useful for automating the management and cleanup of scheduled jobs in Kubernetes clusters, such as removing outdated or unnecessary CronJobs automatically.

Use Case Examples

  1. Deleting a CronJob named 'backup-job' in the 'default' namespace to stop scheduled backups.
  2. Automating cleanup of CronJobs in a specific namespace as part of a CI/CD pipeline.

Properties

Name Meaning
Namespace The Kubernetes namespace where the CronJob resource exists. Defaults to 'default' if not specified.
Resource Name The name of the CronJob resource to delete.

Output

JSON

  • json - The JSON response from Kubernetes after deleting the specified CronJob resource, typically containing status or confirmation details.

Dependencies

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

Troubleshooting

  • If the 'Resource Name' is not provided, the node throws an error indicating that the resource name is required for the delete operation.
  • If Kubernetes credentials are missing or invalid, the node will throw an error indicating no credentials were returned or authentication failed.
  • Ensure the specified namespace and resource name exist in the Kubernetes cluster to avoid resource not found errors.

Discussion