Camel CLI - Configuration
This page covers configuring the Camel CLI — available options, configuration commands, and how to set up your environment.
Camel CLI configurations
The camel.jbang supports 53 options, which are listed below.
| Name | Description | Default | Type |
|---|---|---|---|
|
The version of Apache Camel to use |
String |
|
|
To use a custom Camel version when running or export to Spring Boot |
String |
|
|
Include Camel Wrapper scripts in the exported project for version pinning |
false |
boolean |
|
Additional files to add to classpath (Use commas to separate multiple files). |
String |
|
|
Work directory for compiler. Can be used to write compiled classes or other resources. |
.camel-jbang/compile |
String |
|
Developer console at /q/dev on local HTTP server (port 8080 by default) |
false |
boolean |
|
Additional dependencies (Use commas to separate multiple dependencies). |
String |
|
|
Additional dependencies for Camel Main runtime only |
String |
|
|
Additional dependencies for Quarkus runtime only |
String |
|
|
Additional dependencies for Spring Boot runtime only |
String |
|
|
Whether to allow automatic downloading JAR dependencies (over the internet) |
true |
boolean |
|
Exclude files by name or pattern (Use commas to separate multiple files) |
String |
|
|
Directory where the project will be exported |
. |
String |
|
Whether to force using fresh (i.e. non-cached) resources |
false |
boolean |
|
Maven coordinate (groupId:artifactId:version) |
String |
|
|
Additional groovy source files to export to src/main/resources/camel-groovy directory (Use commas to separate multiple files) |
String |
|
|
Health check at /observe/health on local HTTP server (port 8080 by default) |
false |
boolean |
|
Whether to ignore route loading and compilation errors (use this with care!) |
false |
boolean |
|
Java version |
21 |
String |
|
Enables Java Flight Recorder saving recording to disk on exit |
false |
boolean |
|
Java Flight Recorder profile to use (such as default or profile) |
default |
String |
|
Version to use for jib-maven-plugin when exporting the application |
3.5.2 |
String |
|
Version to use for jkube-maven-plugin if exporting to camel-main and have Kubernetes enabled (jkube.xxx options) |
1.20.0 |
String |
|
Resource YAML fragments for Kubernetes using Eclipse JKube tool (Use commas to separate multiple files). |
String |
|
|
Apache Camel Kamelets version. By default the Kamelets are the same version as Camel. |
String |
|
|
Whether to use lazy bean initialization (can help with complex classloading issues) |
false |
boolean |
|
Local file directory for loading custom Kamelets |
String |
|
|
Whether downloading JARs from ASF Maven Snapshot repository is enabled |
true |
boolean |
|
Whether downloading JARs from Maven Central repository is enabled |
true |
boolean |
|
Optional location of Maven settings.xml file to configure servers, repositories, mirrors, and proxies. If set to false, not even the default /.m2/settings.xml will be used. |
String |
|
|
Optional location of Maven settings-security.xml file to decrypt Maven Settings (settings.xml) file |
String |
|
|
Include Maven Wrapper files in the exported project |
true |
boolean |
|
Embed dev/diagnostics MCP tools on the local HTTP management server (/mcp by default) |
false |
boolean |
|
Metrics (Micrometer and Prometheus) at /observe/metrics on local HTTP server (port 8080 by default) when running standalone Camel |
false |
boolean |
|
File name of open-api spec file (JSON or YAML) to generate routes from the swagger/openapi API spec file. |
String |
|
|
Swagger UI for REST OpenAPI at /q/openapi on local HTTP server (port 8080 by default) |
false |
boolean |
|
Whether to automatic package scan JARs for custom Spring or Quarkus beans making them available for Camel CLI |
false |
boolean |
|
Parent POM coordinate (groupId:artifactId:version) to use in the exported project |
String |
|
|
Allow user to type in required parameters in prompt if not present in application |
false |
boolean |
|
artifactId of Quarkus Platform BOM |
String |
|
|
The base URI of Quarkus Extension Registry |
String |
|
|
groupId of Quarkus Platform BOM |
String |
|
|
version of Quarkus Platform BOM |
String |
|
|
README files included with the integration (Use commas to separate multiple files) |
String |
|
|
Additional Maven repositories for download on-demand (Use commas to separate multiple repositories) |
String |
|
|
Additional resource directories to include recursively, preserving directory structure (Use commas to separate multiple directories) |
String |
|
|
Which runtime to use (camel-main, spring-boot, quarkus) |
String |
|
|
Additional shell script files to export to src/main/scripts directory |
String |
|
|
Source directory for dynamically loading Camel file(s) to run. When using this, then files cannot be specified at the same time. |
String |
|
|
Spring Boot version |
String |
|
|
Stubs all the matching endpoint with the given component name or pattern. Multiple names can be separated by comma. (all = stub all endpoints, remote = stub only remote components). |
String |
|
|
Additional SSL/TLS files to export to src/main/tls directory |
String |
|
|
Verbose output of startup activity (dependency resolution and downloading |
false |
boolean |
Configuration Commands
Store frequently used CLI options so you don’t have to specify them each time:
camel config set camel-version=3.18.4
camel run *
Configuration locations
Camel CLI uses two configuration files:
-
Global:
~/.camel-cli.properties -
Local:
./camel-cli.properties(takes precedence)
Commands target global by default. Use --global=false for local configuration.
These files were previously named .camel-jbang-user.properties (global) and
camel-jbang-user.properties (local). On first run the CLI automatically renames a pre-existing
global ~/.camel-jbang-user.properties to ~/.camel-cli.properties and a pre-existing local
./camel-jbang-user.properties to ./camel-cli.properties. An existing new file is never
overwritten.
|
A set version via camel config set cannot be combined with --camel-version on the command line.
|
Set, unset, list, and get
camel config set gav=com.foo:acme:1.0-SNAPSHOT
camel config set runtime=spring-boot
camel config unset runtime
camel config list
camel config get gav
Placeholder substitution
Configuration values can be referenced as placeholders with #optionName:
camel config set repos=https://maven.repository.my.repo.com/ga
camel run 'Test.java' --repos=#repos,https://packages.atlassian.com/maven-external
Placeholders only work for options that the given command supports. Run camel <command> --help to see available options.
|