Docker
Manage Docker containers, images and networks, and receive Docker events and container statistics.
What’s inside
-
Docker component, URI syntax:
docker:operation
Please refer to the above links for usage and configuration details.
Maven coordinates
<dependency>
<groupId>org.apache.camel.springboot</groupId>
<artifactId>camel-docker-starter</artifactId>
</dependency> Spring Boot Auto-Configuration
The starter supports 23 options, which are listed below.
| Name | Description | Default | Type |
|---|---|---|---|
camel.component.docker.allow-connection-and-credentials-from-headers | Whether to allow overriding the connection and credential settings of the endpoint with the CamelDockerHost, CamelDockerPort, CamelDockerSocketEnabled, CamelDockerSecure, CamelDockerTlsVerify, CamelDockerCertPath, CamelDockerCmdExecFactory, CamelDockerUsername, CamelDockerPassword and CamelDockerServerAddress headers. Disabled by default; enable it only when the header source is trusted, since it lets a message choose the Docker daemon that the client connects to and how, and the registry that receives the username and password of the endpoint. | false | Boolean |
camel.component.docker.autowired-enabled | Whether autowiring is enabled. This is used for automatic autowiring options (the option must be marked as autowired) by looking up in the registry to find if there is a single instance of matching type, which then gets configured on the component. This can be used for automatic configuring JDBC data sources, JMS connection factories, AWS Clients, etc. | true | Boolean |
camel.component.docker.bridge-error-handler | Allows for bridging the consumer to the Camel routing Error Handler, which mean any exceptions (if possible) occurred while the Camel consumer is trying to pickup incoming messages, or the likes, will now be processed as a message and handled by the routing Error Handler. Important: This is only possible if the 3rd party component allows Camel to be alerted if an exception was thrown. Some components handle this internally only, and therefore bridgeErrorHandler is not possible. In other situations we may improve the Camel component to hook into the 3rd party component and make this possible for future releases. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions, that will be logged at WARN or ERROR level and ignored. | false | Boolean |
camel.component.docker.cert-path | The directory with the certificates and the key of the client (ca.pem, cert.pem and key.pem), used when secure is enabled. | String | |
camel.component.docker.cmd-exec-factory | The fully qualified class name of the DockerCmdExecFactory implementation of docker-java that sends the requests to the Docker daemon, such as com.github.dockerjava.netty.NettyDockerCmdExecFactory (the default) or com.github.dockerjava.jaxrs.JerseyDockerCmdExecFactory. | com.github.dockerjava.netty.NettyDockerCmdExecFactory | String |
camel.component.docker.configuration | The shared configuration of the component, which each endpoint copies and then applies its own options to. The option is a org.apache.camel.component.docker.DockerConfiguration type. | DockerConfiguration | |
camel.component.docker.email | Email address associated with the user | String | |
camel.component.docker.enabled | Whether to enable auto configuration of the docker component. This is enabled by default. | Boolean | |
camel.component.docker.host | Docker host. In socket mode (socket=true), the path of the unix socket of the Docker daemon, where the default localhost means /var/run/docker.sock. A host with a tcp:// or unix:// scheme (such as tcp://myhost:2376 or unix:///var/run/docker.sock) is used as is, and then the port and socket options are not used. | localhost | String |
camel.component.docker.lazy-start-producer | Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel’s routing error handlers. Beware that when the first message is processed then creating and starting the producer may take a little time and prolong the total processing time of the processing. | false | Boolean |
camel.component.docker.max-per-route-connections | Not used: the component does not pass this value to the DockerCmdExecFactory. | 100 | Integer |
camel.component.docker.max-total-connections | Not used: the component does not pass this value to the DockerCmdExecFactory. | 100 | Integer |
camel.component.docker.parameters | The parameters of the endpoint URI that are not options, such as containerId=myContainer. The component sets them. Each one is the fallback for the CamelDocker header of the same name, such as containerId for CamelDockerContainerId. | Object> | |
camel.component.docker.password | Password to authenticate with | String | |
camel.component.docker.port | The TCP port of the Docker daemon. Not used in socket mode, or when the host is a tcp:// or unix:// URL. | 2375 | Integer |
camel.component.docker.request-timeout | The timeout in milliseconds to connect to the Docker daemon, and with JerseyDockerCmdExecFactory also to wait for data of a response. Not used with a cmdExecFactory other than NettyDockerCmdExecFactory and JerseyDockerCmdExecFactory. When not set, the defaults of the transport apply. | Integer | |
camel.component.docker.secure | Whether to connect to the Docker daemon with HTTPS, using the certificates in certPath, which is then required. | false | Boolean |
camel.component.docker.server-address | The server address of the Docker registry. | String | |
camel.component.docker.socket | Socket connection mode. When enabled, connects to the unix socket of the Docker daemon, whose path is given by the host option (the default localhost means /var/run/docker.sock), and the port is not used. When disabled, connects over TCP to the host and port. | false | Boolean |
camel.component.docker.tls-verify | Check TLS | false | Boolean |
camel.component.docker.username | User name to authenticate with | String | |
camel.component.docker.follow-redirect-filter | Whether to follow redirect filter. Deprecation note: Not used: nothing reads this option when the Docker client is built | false | Boolean |
camel.component.docker.logging-filter | Whether to use logging filter. Deprecation note: Not used: nothing reads this option when the Docker client is built | false | Boolean |