Kubernetes Component
Available as of Camel 2.17
The Kubernetes component is a component for integrating your application with Kubernetes standalone or on top of Openshift.
Maven users will need to add the following dependency to their pom.xml
for this component:
<dependency> <groupId>org.apache.camel</groupId> <artifactId>camel-kubernetes</artifactId> <version>x.x.x</version> <!-- use the same version as your Camel core version --> </dependency>
URI format
kubernetes:masterUrl[?options]
You can append query options to the URI in the following format, ?option=value&option=value&...
From Camel 2.18: The secrets consumer doesn't exists anymore.
Options
Name | Default Value | Description |
---|---|---|
|
| Mandatory: The Kubernetes master URL |
| Mandatory: The category of producer/consumer. Possible values: namespaces, services, replicationControllers, pods, persistentVolumes, persistentVolumesClaims, secrets, resourcesQuota, serviceAccounts, nodes, configMaps, builds, buildConfigs | |
|
| The username for login to Kubernetes cluster |
|
| The password for login to Kubernetes cluster |
|
| Producer only: The operation that producer will do. Possible values: listNamespaces,listNamespacesByLabels,getNamespace,createNamespace,deleteNamespace,listServices,listServicesByLabels,getService,createService,deleteService,listReplicationControllers, listReplicationControllersByLabels,getReplicationController,createReplicationController,deleteReplicationController,scaleReplicationController,listPods, listPodsByLabels,getPod,createPod,deletePod,listPersistentVolumes,listPersistentVolumesByLabels,getPersistentVolume,listPersistentVolumesClaims,listPersistentVolumesClaimsByLabels, getPersistentVolumeClaim,createPersistentVolumeClaim,deletePersistentVolumeClaim,listSecrets,listSecretsByLabels,getSecret,createSecret,deleteSecret,listResourcesQuota, listResourcesQuotaByLabels,getResourceQuota,createResourceQuota,deleteResourceQuota,listServiceAccounts,listServiceAccountsByLabels,getServiceAccount,createServiceAccount, deleteServiceAccount,listNodes,listNodesByLabels,getNode,listConfigMaps,listConfigMapsByLabels,getConfigMap,createConfigMap,deleteConfigMap,listBuilds,listBuildsByLabels,getBuild,listBuildConfigs,listBuildConfigsByLabels,getBuildConfig |
|
| The api Version to use |
|
| Path to CA cert file |
|
| Path to CA cert data |
|
| Path to client cert file |
|
| Path to client cert data |
|
| Key algorithm used by client |
|
| Path to client key file |
|
| Path to client key data |
|
| Client key passphrase |
oauthToken |
| Authorization token |
trustCerts |
| Define if the certs are trusted by default |
namespaceName |
| Consumer only: The namespace the consumer will watch |
poolSize |
| Consumer only: The Threadpool size for the Kubernetes consumer |
namespace |
| Consumer only: The Namespace to watch for the consumer |
labelKey |
| Consumer only: The label key to watch for the consumer |
labelValue |
| Consumer only: The label value to watch for the consumer |
resourceName |
| Consumer only: The resource name to watch for the consumer |
Headers
Name | Type | Description |
---|---|---|
CamelKubernetesOperation | String | The Producer operation |
CamelKubernetesNamespaceName | String | The Namespace name |
CamelKubernetesNamespaceLabels | Map | The Namespace Labels |
CamelKubernetesServiceLabels | Map | The Service labels |
CamelKubernetesServiceName | String | The Service name |
CamelKubernetesServiceSpec | io.fabric8.kubernetes.api.model.ServiceSpec | The Spec for a Service |
CamelKubernetesReplicationControllersLabels | Map | Replication controller labels |
CamelKubernetesReplicationControllerName | String | Replication controller name |
CamelKubernetesReplicationControllerSpec | io.fabric8.kubernetes.api.model.ReplicationControllerSpec | The Spec for a Replication Controller |
CamelKubernetesReplicationControllerReplicas | Integer | The number of replicas for a Replication Controller during the Scale operation |
CamelKubernetesPodsLabels | Map | Pod labels |
CamelKubernetesPodName | String | Pod name |
CamelKubernetesPodSpec | io.fabric8.kubernetes.api.model.PodSpec | The Spec for a Pod |
CamelKubernetesPersistentVolumesLabels | Map | Persistent Volume labels |
CamelKubernetesPersistentVolumesName | String | Persistent Volume name |
CamelKubernetesPersistentVolumesClaimsLabels | Map | Persistent Volume Claim labels |
CamelKubernetesPersistentVolumesClaimsName | String | Persistent Volume Claim name |
CamelKubernetesPersistentVolumesClaimsSpec | io.fabric8.kubernetes.api.model.PersistentVolumeClaimSpec | The Spec for a Persistent Volume claim |
CamelKubernetesSecretsLabels | Map | Secret labels |
CamelKubernetesSecretsName | String | Secret name |
CamelKubernetesSecret | io.fabric8.kubernetes.api.model.Secret | A Secret Object |
CamelKubernetesResourcesQuotaLabels | Map | Resource Quota labels |
CamelKubernetesResourcesQuotaName | String | Resource Quota name |
CamelKubernetesResourceQuotaSpec | io.fabric8.kubernetes.api.model.ResourceQuotaSpec | The Spec for a Resource Quota |
CamelKubernetesServiceAccountsLabels | Map | Service Account labels |
CamelKubernetesServiceAccountName | String | Service Account name |
CamelKubernetesServiceAccount | io.fabric8.kubernetes.api.model.ServiceAccount | A Service Account object |
CamelKubernetesNodesLabels | Map | Node labels |
CamelKubernetesNodeName | String | Node name |
CamelKubernetesBuildsLabels | Map | Openshift Build labels |
CamelKubernetesBuildName | String | Openshift Build name |
CamelKubernetesBuildConfigsLabels | Map | Openshift Build Config labels |
CamelKubernetesBuildConfigName | String | Openshift Build Config name |
CamelKubernetesEventAction | io.fabric8.kubernetes.client.Watcher.Action | Action watched by the consumer |
CamelKubernetesEventTimestamp | String | Timestamp of the action watched by the consumer |
CamelKubernetesConfigMapName | String | ConfigMap name |
CamelKubernetesConfigMapsLabels | Map | ConfigMap labels |
CamelKubernetesConfigData | Map | ConfigMap Data |