Actions90
- Jobs Actions
- Namespaces Actions
- Pods Actions
- Services Actions
- Deployments Actions
- ReplicaSets Actions
- StatefulSets Actions
- DaemonSets Actions
- CronJobs Actions
Overview
This node allows users to interact with Kubernetes resources programmatically within n8n workflows. Specifically, the Delete operation for the CronJobs resource enables users to delete a specified CronJob from a Kubernetes cluster.
Common scenarios where this node is beneficial include:
- Automating cleanup of scheduled jobs that are no longer needed.
- Managing lifecycle of Kubernetes CronJobs as part of CI/CD pipelines.
- Integrating Kubernetes resource management into broader automation workflows.
For example, you might use this node to delete a CronJob after it has completed successfully or if a certain condition in your workflow requires removing scheduled tasks dynamically.
Properties
| Name | Meaning |
|---|---|
| Namespace | The Kubernetes namespace where the CronJob exists. Defaults to "default". |
| Resource Name | The exact name of the CronJob resource to delete. |
Output
The output is a JSON array containing the response from the Kubernetes API after attempting to delete the specified CronJob. This typically includes status information about the deletion request.
Example output structure (simplified):
[
{
"status": "Success",
"details": {
"name": "example-cronjob",
"namespace": "default"
}
}
]
No binary data is produced by this operation.
Dependencies
- Requires valid Kubernetes API credentials configured in n8n to authenticate and authorize requests.
- The node depends on a Kubernetes client utility internally to communicate with the Kubernetes API server.
- The user must have appropriate permissions to delete CronJobs in the specified namespace.
Troubleshooting
No credentials got returned!
This error indicates missing or misconfigured Kubernetes API credentials. Ensure that the credentials are properly set up and linked to the node.Resource not found or permission denied errors
Verify that the specified namespace and CronJob name exist and that the credentials have sufficient permissions to delete the resource.Invalid input errors
Make sure theNamespaceandResource Namefields are correctly filled. The namespace defaults to"default"if left empty.