Actions40
- Node Actions
- Namespace Actions
- Deployment Actions
- Service Actions
- Pod Actions
- StatefulSet Actions
- ConfigMap Actions
- Secret Actions
- Job Actions
- CronJob Actions
Overview
This node enables interaction with Rancher and Kubernetes APIs, specifically allowing users to manage Kubernetes resources programmatically within n8n workflows. For the ConfigMap Create operation, it facilitates creating a new ConfigMap resource in a specified Kubernetes cluster namespace. This is useful for storing configuration data as key-value pairs that pods can consume.
Common scenarios include:
- Automating deployment pipelines where ConfigMaps need to be created or updated dynamically.
- Managing environment-specific configurations without rebuilding container images.
- Centralizing configuration management for microservices running on Kubernetes.
Example: Automatically create a ConfigMap containing application settings before deploying an app, ensuring the app reads the latest config values at startup.
Properties
| Name | Meaning |
|---|---|
| Name | The name of the ConfigMap resource to create. |
| Cluster Name or ID | Select the target Kubernetes cluster by name or ID where the ConfigMap will be created. |
| Project Name or ID | Select the project within the cluster where the ConfigMap will reside. |
| Namespace Name or ID | Select the namespace inside the project where the ConfigMap will be created. |
| Labels | Optional key-value pairs to label the ConfigMap for identification or grouping purposes. |
| Annotations | Optional key-value pairs to annotate the ConfigMap with metadata for tooling or informational use. |
Output
The node outputs JSON data representing the created ConfigMap resource as returned by the Rancher/Kubernetes API. This typically includes details such as:
- Metadata (name, namespace, labels, annotations)
- Data stored in the ConfigMap (key-value pairs)
- Resource version and status information
No binary data output is produced by this operation.
Dependencies
- Requires access to a Rancher or Kubernetes cluster API.
- Needs an API authentication token or API key credential configured in n8n to authenticate requests.
- The user must have appropriate permissions to create ConfigMaps in the specified cluster, project, and namespace.
Troubleshooting
- Authentication errors: Ensure the API key or token credential is valid and has sufficient permissions.
- Resource not found: Verify that the specified cluster, project, and namespace exist and are accessible.
- Name conflicts: Creating a ConfigMap with a name that already exists in the namespace may cause errors; consider using unique names or update operations instead.
- Invalid labels/annotations: Keys and values must conform to Kubernetes naming conventions; invalid entries may cause request failures.
- Network issues: Connectivity problems to the Kubernetes API endpoint will prevent successful creation.
Links and References
- Kubernetes ConfigMap Documentation
- Rancher API Reference
- n8n Expressions Documentation (for dynamic property values)