Skip to main content

jEAP CLI

jeap-cli is a command-line interface tool designed to streamline the management of applications built using the jEAP framework. It provides functionalities for version migrations, initializing new projects, and other essential tasks to facilitate efficient application development and maintenance.

Installation

You can install jEAP CLI directly from the command line using curl. This will download and install the launcher script system-wide under /usr/local/bin/jeap, making the jeap command available in your environment.

curl -sSL https://raw.githubusercontent.com/jeap-admin-ch/jeap-cli/main/install.sh | bash

The CLI will update itself regularly.

Requirements

  • A working local Docker environment
  • curl installed on your system
  • sudo installed if you want to install the CLI system-wide
  • Linux (tested on Ubuntu, works on most distributions) or Mac OS X

Configuration

The CLI can be configured using environment variables:

VariableDescription
JEAP_CLI_IMAGEOverride the Docker image used (default: ghcr.io/jeap-admin-ch/jeap-cli:latest)
JEAP_CLI_VERBOSEEnable verbose mode to show the Docker command being executed
JEAP_CLI_NO_HOST_CERTSSet to 1 to disable automatic mounting of host CA certificates

Proxy and Certificate Support

The CLI automatically:

  • Passes proxy environment variables (HTTP_PROXY, HTTPS_PROXY, NO_PROXY) to the container
  • Mounts host CA certificates from /etc/ssl/certs for curl/wget to work behind corporate proxies

To disable automatic certificate mounting use:

JEAP_CLI_NO_HOST_CERTS=1 ./jeap <command>

Available Commands

CommandDescription
migrate java-25Migrate a jEAP application to Java 25
migrate spring-boot-4Migrate a jEAP application to Spring Boot 4
pas-backfill sendSubmit a backfill job to the PAS
pas-backfill reportRead the backfill job report from the PAS

Building

This section describes how to build the jEAP CLI from source. Note that for native image builds and local CLI docker image builds, a GraalVM installation is required. When using SDKMAN, you can install GraalVM with the following command:

sdk install java 25-graalce
sdk use java 25-graalce

Non-native build for Java Hotspot

To create a standard Java executable JAR file, run the following command. The JAR file will be generated in the jeap-cli/target directory.

./mvnw clean package

Native build with GraalVM

To create a native executable using GraalVM, run the following command. This requires GraalVM to be installed and configured in the build environment. The native executable will be generated in the jeap-cli/target directory. The release version of the CLI is built as a native executable to improve startup time.

./mvnw clean package -Pnative

Local Docker Image Build

The production CLI is deployed as a Docker image that includes the native executable and Maven for building projects. For testing the resulting image in the local development environment, use the provided build script that handles both the native build and Docker image creation.

Make sure your JAVA_HOME environment variable is set to a GraalVM JDK. For example by using sdkman:

sdk use java 25-graalce

Then run the following command:

./local-docker-image-build.sh

The script automatically detects and handles:

  • Proxy configuration from environment variables (HTTP_PROXY, HTTPS_PROXY, NO_PROXY)
  • Corporate CA certificates from the system trust store are passed to the CLI container

The resulting Docker image will be tagged as jeap-cli:latest, and can be run using the following command:

export JEAP_CLI_IMAGE=jeap-cli:latest && ./jeap help