The English version of quarkus.io is the official project site. Translated sites are community supported on a best-effort basis.

コンテナーイメージ

Quarkus は、コンテナーイメージをビルド (およびプッシュ) するためのエクステンションを提供しています。現在は以下をサポートしています。

コンテナーイメージのエクステンション

Jib

エクステンション quarkus-container-image-jib は、コンテナーイメージのビルドを実行するために Jib を使用しています。Jib を Quarkus で使用する主な利点は、すべての依存関係 (target/lib の下にあるすべてのもの) が実際のアプリケーションとは別のレイヤーにキャッシュされるため、リビルドが非常に高速かつ小規模に (プッシュする場合) 行えることです。このエクステンションを使用するもう 1 つの重要な利点は、コンテナーイメージレジストリーにプッシュする機能さえあれば、専用のクライアントサイドツール (Docker など) やデーモンプロセス (Docker デーモンなど) を実行しなくてもコンテナーイーメージを作成できることです。

この機能を使用するには、以下のエクステンションをプロジェクトに追加します。

コマンドラインインタフェース
quarkus extension add container-image-jib
Maven
./mvnw quarkus:add-extension -Dextensions='container-image-jib'
Gradle
./gradlew addExtension --extensions='container-image-jib'
必要なことがコンテナーイメージを構築するだけで、レジストリーへのプッシュが不要な場合 (基本的には quarkus.container-image.build=true を設定して quarkus.container-image.push のままにしておくことで、デフォルトは false になります)、このエクステンションはコンテナーイメージを作成し、Docker デーモンに登録します。これは、Docker がイメージのビルドには使われなくても必要であることを意味します。また、このモードを使用すると、docker images を実行するとコンテナーイメージが表示されます。

追加ファイルの追加

コンテナーイメージに追加のファイル(Quarkus のビルドで作成されたもの以外)を追加する必要がある場合があります。このような場合に対応するため、Quarkus は、src/main/jib 以下のファイルをすべてビルドされたコンテナーイメージにコピーします (これは、Jib Maven や Gradle プラグインがサポートしているのと基本的に同じ考え方です)。例えば、src/main/jib/foo/bar が存在すると、/foo/bar がコンテナファイルシステムに追加されます。

JVM デバッグ

ビルドしたコンテナイメージでは、実行時に条件付きでJavaデバッグを有効にする必要がある場合があります。

ベース・イメージが変更されていない場合(したがって ubi8/openjdk-11-runtimeubi8/openjdk-17-runtime 、または ubi8/openjdk-21-runtime が使用されている場合)、起動時にJVMをデバッグ・ポートでリッスンさせるために、 quarkus.jib.jvm-additional-arguments 設定プロパティを使用できます。

具体的な構成例:

quarkus.jib.jvm-additional-arguments=-agentlib:jdwp=transport=dt_socket\\,server=y\\,suspend=n\\,address=*:5005

他のベースイメージでは、環境変数の設定によりデバッグが可能になる起動スクリプトが提供されている場合があり、その場合はコンテナの起動時に環境変数を設定します。

カスタムエントリーポイント

最後に、 quarkus.jib.jvm-entrypoint 設定プロパティを使用すると、コンテナのエントリポイントを完全にオーバーライドすることができるため、JVMのデバッグ構成をハードコードするか、詳細を処理するスクリプトを指定することができます。

たとえば、ベースイメージ ubi8/openjdk-11-runtimeubi8/openjdk-17-runtimeubi8/openjdk-21-runtime を使用してコンテナをビルドする場合、アプリケーションのプロパティファイルにエントリポイントをハードコードすることができます。

application.properties の例
quarkus.jib.jvm-entrypoint=java,-Dcustom.param=custom_value,-jar,quarkus-run.jar

または、カスタムスタートアップスクリプトを作成し、プロパティファイルで参照することもできます。この方法は、環境変数を使用してアプリケーションのパラメータを設定する必要がある場合に有効です。

application.properties の例
quarkus.jib.jvm-entrypoint=/bin/sh,run-java.sh
例 src/main/jib/home/jboss/run-java.sh
java \
  -Djavax.net.ssl.trustStore=/deployments/truststore \
  -Djavax.net.ssl.trustStorePassword="$TRUST_STORE_PASSWORD" \
  -jar quarkus-run.jar
/home/jboss は、ベースイメージ ubi8/openjdk-11-runtime, ubi8/openjdk-17-runtime, ubi8/openjdk-21-runtime ( ubi8/openjdk-17-runtime 用の Dockerfile ) にある Quarkus バイナリすべての WORKDIR です。

マルチモジュールプロジェクトとレイヤリング

Quarkusアプリケーションを1つのモジュールとし、さらにさまざまなサポートプロジェクトの依存関係を他のモジュールとして含むマルチモジュールプロジェクトを構築する場合、Quarkusでは、サポートモジュールが通常のアプリケーション依存関係よりも頻繁に変更されることを想定して、それらのサポートモジュールを他のアプリケーション依存関係とは別のコンテナイメージレイヤーに配置することをサポートしています。このため、アプリケーションの依存関係に変更がない場合は、リビルドを高速に行うことができます。

この機能を有効にするには、ビルドツール起動時にシステムプロパティとして、またはビルドツールプロパティとして、プロパティ quarkus.bootstrap.workspace-discoverytrue に設定する必要があります。このプロパティは、ビルドプロセスの非常に早い段階で認識される必要があるため、 application.properties で設定しても正しく 機能しません

AppCDS

Quarkusは、Jibを使用したコンテナイメージの生成時に、 アプリケーションクラスデータ共有 アーカイブを生成して含めることをサポートしています。詳細については、 AppCDSのドキュメント を参照してください。

Docker

エクステンション quarkus-container-image-docker は、Docker ビルドを実行するために src/main/docker 下で Docker バイナリーと生成された Dockerfiles を使用しています。

この機能を使用するには、以下のエクステンションをプロジェクトに追加します。

コマンドラインインタフェース
quarkus extension add container-image-docker
Maven
./mvnw quarkus:add-extension -Dextensions='container-image-docker'
Gradle
./gradlew addExtension --extensions='container-image-docker'

quarkus-container-image-docker エクスンテンションは、docker buildx build を使って、 マルチプラットフォーム (またはマルチアーキ) イメージを作成することができます。以下の Dockerオプション のセクションにある quarkus.docker.buildx.* の設定項目を参照してください。

docker buildx build は、単一のプラットフォーム向けにビルドする場合のみ、ビルド結果の docker images への読み込み をサポートします。したがって、 quarkus.docker.buildx.platform プロパティに複数の引数を指定した場合、結果のイメージは docker images にロードされません。 quarkus.docker.buildx.platform が省略された場合、または単一のプラットフォームのみが指定された場合は、その後 docker images にロードされるようになります。

OpenShift

エクステンション quarkus-container-image-openshift は、OpenShift クラスタ内でコンテナのビルドを実行するために OpenShift バイナリビルドを使用しています。バイナリビルドの背景にある考え方は、アーティファクトとその依存関係をクラスタにアップロードするだけで、ビルド中にそれらがビルダーイメージ(デフォルトは fabric8/s2i-java )にマージされるというものです。

このアプローチの利点は、クラスターへの変更を簡単にロールアウトできる OpenShift の DeploymentConfig と組み合わせることができることです。

この機能を使用するには、以下のエクステンションをプロジェクトに追加します。

コマンドラインインタフェース
quarkus extension add container-image-openshift
Maven
./mvnw quarkus:add-extension -Dextensions='container-image-openshift'
Gradle
./gradlew addExtension --extensions='container-image-openshift'

OpenShiftのビルドでは、 BuildConfig 、ビルダーイメージ用と出力イメージ用の2つの ImageStream リソースを作成する必要があります。このようなオブジェクトの作成は、Quarkus Kubernetesエクステンションによって行われます。

Buildpack

quarkus-container-image-buildpack は、コンテナイメージのビルドを行うために buildpacks を使用しています。buildpacksは、実際のビルドにDockerデーモンを使用します。buildpacksはDockerの代替品をサポートしていますが、このエクステンションはDockerでのみ動作します。

さらに、ユーザーはどのビルドイメージを使用するかを設定する必要があります(デフォルトのイメージは提供されていません)。例えば、以下のようになります。

quarkus.buildpack.jvm-builder-image=<jvm builder image>

またはネイティブの場合、

quarkus.buildpack.native-builder-image=<native builder image>

この機能を使用するには、以下のエクステンションをプロジェクトに追加します。

コマンドラインインタフェース
quarkus extension add container-image-buildpack
Maven
./mvnw quarkus:add-extension -Dextensions='container-image-buildpack'
Gradle
./gradlew addExtension --extensions='container-image-buildpack'
buildpack コンテナイメージエクステンションを使用する際には、プロパティ設定に quarkus.container-image.build=true を追加しないことを強くお勧めします。代わりにビルドコマンドのオプションとして渡すことをお勧めします。

ビルド

プロジェクト用のコンテナーイメージを作成するには、Quarkus がサポートしている方法のいずれかで、 quarkus.container-image.build=true を設定する必要があります。

コマンドラインインタフェース
quarkus build -Dquarkus.container-image.build=true
Maven
./mvnw install -Dquarkus.container-image.build=true
Gradle
./gradlew build -Dquarkus.container-image.build=true
ネイティブコンテナイメージをビルドしたいときに、すでに既存のネイティブイメージがある場合は、 -Dquarkus.native.reuse-existing=true を設定すれば、ネイティブイメージのビルドは再実行されません。

@QuarkusIntegrationTest の利用

作成されたイメージでテストを実行するためには、Quarkus がサポートしている方法のいずれかで、 quarkus.container-image.build=true を設定する必要があります。

Maven
./mvnw verify -Dquarkus.container-image.build=true
Gradle
./gradlew quarkusIntTest -Dquarkus.container-image.build=true

プッシュ

プロジェクトにコンテナーイメージをプッシュするには、Quarkus がサポートしている方法のいずれかで、quarkus.container-image.push=true を設定する必要があります。

コマンドラインインタフェース
quarkus build -Dquarkus.container-image.push=true
Maven
./mvnw install -Dquarkus.container-image.push=true
Gradle
./gradlew build -Dquarkus.container-image.push=true
レジストリーが設定されていない場合 (quarkus.container-image.registry を使用) は、 docker.io がデフォルトとして使用されます。

複数のエクステンションから選択する

複数のエクステンションを同じビルドの一部として使用することは意味がありません。複数のコンテナイメージエクステンションが存在する場合は、エラーが発生してユーザーに通知されます。ユーザーは、不要なエクステンションを削除するか、 application.properties を使用してエクステンションを選択することができます。

例えば、 container-image-dockercontainer-image-openshift の両方が存在し、ユーザーが container-image-docker を使う必要がある場合:

quarkus.container-image.builder=docker

systemd-notify との統合

QuarkusアプリケーションをPodmanとSystemdでLinuxサービスとしてデプロイするためにコンテナイメージをビルドする場合、 次のように Quarkus Systemd Notify Extension をアプリケーションの一部として含めることを検討するとよいかもしれません:

コマンドラインインタフェース
quarkus extension add io.quarkiverse.systemd.notify:quarkus-systemd-notify
Maven
./mvnw quarkus:add-extension -Dextensions='io.quarkiverse.systemd.notify:quarkus-systemd-notify'
Gradle
./gradlew addExtension --extensions='io.quarkiverse.systemd.notify:quarkus-systemd-notify'

カスタマイズ

以下のプロパティーを使用して、コンテナーイメージのビルドプロセスをカスタマイズすることができます。

コンテナーイメージオプション

ビルド時に固定される構成プロパティ - 他のすべての構成プロパティは実行時にオーバーライド可能

Configuration property

デフォルト

The group the container image will be part of

Environment variable: QUARKUS_CONTAINER_IMAGE_GROUP

Show more

string

The name of the container image. If not set defaults to the application name

Environment variable: QUARKUS_CONTAINER_IMAGE_NAME

Show more

string

${quarkus.application.name:unset}

The tag of the container image. If not set defaults to the application version

Environment variable: QUARKUS_CONTAINER_IMAGE_TAG

Show more

string

${quarkus.application.version:latest}

Additional tags of the container image.

Environment variable: QUARKUS_CONTAINER_IMAGE_ADDITIONAL_TAGS

Show more

list of string

The container registry to use

Environment variable: QUARKUS_CONTAINER_IMAGE_REGISTRY

Show more

string

Represents the entire image string. If set, then group, name, registry, tags, additionalTags are ignored

Environment variable: QUARKUS_CONTAINER_IMAGE_IMAGE

Show more

string

The username to use to authenticate with the registry where the built image will be pushed

Environment variable: QUARKUS_CONTAINER_IMAGE_USERNAME

Show more

string

The password to use to authenticate with the registry where the built image will be pushed

Environment variable: QUARKUS_CONTAINER_IMAGE_PASSWORD

Show more

string

Whether or not insecure registries are allowed

Environment variable: QUARKUS_CONTAINER_IMAGE_INSECURE

Show more

boolean

false

Whether or not a image build will be performed.

Environment variable: QUARKUS_CONTAINER_IMAGE_BUILD

Show more

boolean

Whether or not an image push will be performed.

Environment variable: QUARKUS_CONTAINER_IMAGE_PUSH

Show more

boolean

The name of the container image extension to use (e.g. docker, jib, s2i). The option will be used in case multiple extensions are present.

Environment variable: QUARKUS_CONTAINER_IMAGE_BUILDER

Show more

string

Custom labels to add to the generated image.

Environment variable: QUARKUS_CONTAINER_IMAGE_LABELS

Show more

Map<String,String>

CI 環境の利用

さまざまな CI 環境では、Quarkus アプリケーションを作成してレジストリーをプッシュするために、コンテナーイメージ Quarkus エクステンションと組み合わせることで、すぐに使えるコンテナーイメージレジストリ-を利用できます。

例えば、 GitLab はこのようなレジストリーを提供しており、提供されている CI 環境では、環境変数 CI_REGISTRY_IMAGE (詳しくは GitLab の ドキュメント を参照) を利用できるようになっています。なお、Quarkus ではこのように利用できます。

quarkus.container-image.image=${CI_REGISTRY_IMAGE}
プロパティと環境変数を組み合わせる方法については、 こちらをご覧ください。

Jib オプション

一般的なコンテナーイメージのオプションに加えて、container-image-jib では以下のオプションも用意されています。

ビルド時に固定される設定プロパティ - 他のすべての設定プロパティは、実行時にオーバーライド可能

Configuration property

デフォルト

The base image to be used when a container image is being produced for the jar build. When the application is built against Java 21 or higher, registry.access.redhat.com/ubi8/openjdk-21-runtime:1.18 is used as the default. Otherwise registry.access.redhat.com/ubi8/openjdk-17-runtime:1.18 is used as the default.

Environment variable: QUARKUS_JIB_BASE_JVM_IMAGE

Show more

string

The base image to be used when a container image is being produced for the native binary build. The default is "quay.io/quarkus/quarkus-micro-image". You can also use "registry.access.redhat.com/ubi8/ubi-minimal" which is a bigger base image, but provide more built-in utilities such as the microdnf package manager.

Environment variable: QUARKUS_JIB_BASE_NATIVE_IMAGE

Show more

string

quay.io/quarkus/quarkus-micro-image:2.0

The JVM arguments to pass to the JVM when starting the application

Environment variable: QUARKUS_JIB_JVM_ARGUMENTS

Show more

list of string

-Djava.util.logging.manager=org.jboss.logmanager.LogManager

Additional JVM arguments to pass to the JVM when starting the application

Environment variable: QUARKUS_JIB_JVM_ADDITIONAL_ARGUMENTS

Show more

list of string

Additional arguments to pass when starting the native application

Environment variable: QUARKUS_JIB_NATIVE_ARGUMENTS

Show more

list of string

If this is set, then it will be used as the entry point of the container image. There are a few things to be aware of when creating an entry point

  • Entrypoint "INHERIT" means to inherit entrypoint from base image, jvmArguments field is used for arguments

  • A valid entrypoint is jar package specific (see quarkus.package.type)

  • A valid entrypoint depends on the location of both the launching scripts and the application jar file. To that end it’s helpful to remember that when fast-jar packaging is used (the default), all necessary application jars are added to the /work directory and that the same directory is also used as the working directory. When legacy-jar or uber-jar are used, the application jars are unpacked under the /app directory and that directory is used as the working directory.

  • Even if the jvmArguments field is set, it is ignored completely unless entrypoint is "INHERIT" When this is not set, a proper default entrypoint will be constructed. As a final note, a very useful tool for inspecting container image layers that can greatly aid when debugging problems with endpoints is dive

Environment variable: QUARKUS_JIB_JVM_ENTRYPOINT

Show more

list of string

If this is set, then it will be used as the entry point of the container image. There are a few things to be aware of when creating an entry point

  • Entrypoint "INHERIT" means to inherit entrypoint from base image, nativeArguments field is used for arguments

  • A valid entrypoint depends on the location of both the launching scripts and the native binary file. To that end it’s helpful to remember that the native application is added to the /work directory and that and the same directory is also used as the working directory

  • Even if the nativeArguments field is set, it is ignored completely unless entrypoint is "INHERIT" When this is not set, a proper default entrypoint will be constructed. As a final note, a very useful tool for inspecting container image layers that can greatly aid when debugging problems with endpoints is dive

Environment variable: QUARKUS_JIB_NATIVE_ENTRYPOINT

Show more

list of string

The username to use to authenticate with the registry used to pull the base JVM image

Environment variable: QUARKUS_JIB_BASE_REGISTRY_USERNAME

Show more

string

The password to use to authenticate with the registry used to pull the base JVM image

Environment variable: QUARKUS_JIB_BASE_REGISTRY_PASSWORD

Show more

string

The ports to expose

Environment variable: QUARKUS_JIB_PORTS

Show more

list of int

${quarkus.http.port:8080}

The user to use in generated image

Environment variable: QUARKUS_JIB_USER

Show more

string

The working directory to use in the generated image. The default value is chosen to work in accordance with the default base image.

Environment variable: QUARKUS_JIB_WORKING_DIRECTORY

Show more

string

/home/jboss

Controls the optimization which skips downloading base image layers that exist in a target registry. If the user does not set this property, then read as false. If true, base image layers are always pulled and cached. If false, base image layers will not be pulled/cached if they already exist on the target registry.

Environment variable: QUARKUS_JIB_ALWAYS_CACHE_BASE_IMAGE

Show more

boolean

false

List of target platforms. Each platform is defined using the pattern:

<os>|<arch>[/variant]|<os>/<arch>[/variant]

for example:

linux/amd64,linux/arm64/v8

If not specified, OS default is linux and architecture default is amd64. If more than one platform is configured, it is important to note that the base image has to be a Docker manifest or an OCI image index containing a version of each chosen platform. The feature does not work with native images, as cross-compilation is not supported. This configuration is based on an incubating feature of Jib. See Jib FAQ for more information.

Environment variable: QUARKUS_JIB_PLATFORMS

Show more

list of string

The path of a file in which the digest of the generated image will be written. If the path is relative, the base path is the output directory of the build tool.

Environment variable: QUARKUS_JIB_IMAGE_DIGEST_FILE

Show more

string

jib-image.digest

The path of a file in which the id of the generated image will be written. If the path is relative, the base path is the output directory of the build tool.

Environment variable: QUARKUS_JIB_IMAGE_ID_FILE

Show more

string

jib-image.id

Whether or not to operate offline.

Environment variable: QUARKUS_JIB_OFFLINE_MODE

Show more

boolean

false

Name of binary used to execute the docker commands. This is only used by Jib when the container image is being built locally.

Environment variable: QUARKUS_JIB_DOCKER_EXECUTABLE_NAME

Show more

string

Whether to set the creation time to the actual build time. Otherwise, the creation time will be set to the Unix epoch (00:00:00, January 1st, 1970 in UTC). See Jib FAQ for more information

Environment variable: QUARKUS_JIB_USE_CURRENT_TIMESTAMP

Show more

boolean

true

Whether to set the modification time (last modified time) of the files put by Jib in the image to the actual build time. Otherwise, the modification time will be set to the Unix epoch (00:00:00, January 1st, 1970 in UTC). If the modification time is constant (flag is set to false so Unix epoch is used) across two consecutive builds, the docker layer sha256 digest will be different only if the actual files added by Jib to the docker layer were changed. More exactly, having 2 consecutive builds will generate different docker layers only if the actual content of the files within the docker layer was changed. If the current timestamp is used the sha256 digest of the docker layer will always be different even if the content of the files didn’t change.

Environment variable: QUARKUS_JIB_USE_CURRENT_TIMESTAMP_FILE_MODIFICATION

Show more

boolean

true

The directory to use for caching base image layers. If not specified, the Jib default directory is used.

Environment variable: QUARKUS_JIB_BASE_IMAGE_LAYERS_CACHE

Show more

string

Environment variable: QUARKUS_JIB_APPLICATION_LAYERS_CACHE

string

Environment variables to add to the container image

Environment variable: QUARKUS_JIB_ENVIRONMENT_VARIABLES

Show more

Map<String,String>

Sets environment variables used by the Docker executable. This is only used by Jib when the container image is being built locally.

Environment variable: QUARKUS_JIB_DOCKER_ENVIRONMENT

Show more

Map<String,String>

Docker オプション

一般的なコンテナーイメージのオプションに加えて、container-image-docker では以下のオプションも用意されています。

ビルド時に固定される設定プロパティ - 他のすべての設定プロパティは、実行時にオーバーライド可能

Configuration property

デフォルト

Path to the JVM Dockerfile. If set to an absolute path then the absolute path will be used, otherwise the path will be considered relative to the project root. If not set src/main/docker/Dockerfile.jvm will be used.

Environment variable: QUARKUS_DOCKER_DOCKERFILE_JVM_PATH

Show more

string

src/main/docker/Dockerfile.jvm

Path to the native Dockerfile. If set to an absolute path then the absolute path will be used, otherwise the path will be considered relative to the project root. If not set src/main/docker/Dockerfile.native will be used.

Environment variable: QUARKUS_DOCKER_DOCKERFILE_NATIVE_PATH

Show more

string

src/main/docker/Dockerfile.native

Images to consider as cache sources. Values are passed to docker build via the cache-from option

Environment variable: QUARKUS_DOCKER_CACHE_FROM

Show more

list of string

The networking mode for the RUN instructions during build

Environment variable: QUARKUS_DOCKER_NETWORK

Show more

string

Name of binary used to execute the docker commands. This setting can override the global container runtime detection.

Environment variable: QUARKUS_DOCKER_EXECUTABLE_NAME

Show more

string

Additional arbitrary arguments passed to the executable when building the container image.

Environment variable: QUARKUS_DOCKER_ADDITIONAL_ARGS

Show more

list of string

Build args passed to docker via --build-arg

Environment variable: QUARKUS_DOCKER_BUILD_ARGS

Show more

Map<String,String>

Configuration for Docker Buildx options

デフォルト

Which platform(s) to target during the build. See https://docs.docker.com/engine/reference/commandline/buildx_build/#platform

Environment variable: QUARKUS_DOCKER_BUILDX_PLATFORM

Show more

list of string

Sets the export action for the build result. See https://docs.docker.com/engine/reference/commandline/buildx_build/#output. Note that any filesystem paths need to be absolute paths, not relative from where the command is executed from.

Environment variable: QUARKUS_DOCKER_BUILDX_OUTPUT

Show more

string

Set type of progress output (auto, plain, tty). Use plain to show container output (default “auto”). See https://docs.docker.com/engine/reference/commandline/buildx_build/#progress

Environment variable: QUARKUS_DOCKER_BUILDX_PROGRESS

Show more

string

OpenShift オプション

一般的なコンテナ・イメージ・オプションに加えて、 container-image-openshift は以下のオプションも用意されています。

ビルド時に固定される設定プロパティ - 他のすべての設定プロパティは、実行時にオーバーライド可能

Configuration property

デフォルト

The build config strategy to use.

Environment variable: QUARKUS_OPENSHIFT_BUILD_STRATEGY

Show more

binary, docker

binary

The base image to be used when a container image is being produced for the jar build. The value of this property is used to create an ImageStream for the builder image used in the Openshift build. When it references images already available in the internal Openshift registry, the corresponding streams are used instead. When the application is built against Java 21 or higher, registry.access.redhat.com/ubi8/openjdk-21:1.18 is used as the default. Otherwise registry.access.redhat.com/ubi8/openjdk-17:1.18 is used as the default.

Environment variable: QUARKUS_OPENSHIFT_BASE_JVM_IMAGE

Show more

string

The base image to be used when a container image is being produced for the native binary build. The value of this property is used to create an ImageStream for the builder image used in the Openshift build. When it references images already available in the internal Openshift registry, the corresponding streams are used instead.

Environment variable: QUARKUS_OPENSHIFT_BASE_NATIVE_IMAGE

Show more

string

quay.io/quarkus/ubi-quarkus-native-binary-s2i:2.0

The default Dockerfile to use for jvm builds

Environment variable: QUARKUS_OPENSHIFT_JVM_DOCKERFILE

Show more

string

src/main/docker/Dockerfile.jvm

The default Dockerfile to use for native builds

Environment variable: QUARKUS_OPENSHIFT_NATIVE_DOCKERFILE

Show more

string

src/main/docker/Dockerfile.native

The JVM arguments to pass to the JVM when starting the application

Environment variable: QUARKUS_OPENSHIFT_JVM_ARGUMENTS

Show more

list of string

Additional arguments to pass when starting the native application

Environment variable: QUARKUS_OPENSHIFT_NATIVE_ARGUMENTS

Show more

list of string

The directory where the jar is added during the assemble phase. This is dependent on the S2I image and should be supplied if a non default image is used.

Environment variable: QUARKUS_OPENSHIFT_JAR_DIRECTORY

Show more

string

The resulting filename of the jar in the S2I image. This option may be used if the selected S2I image uses a fixed name for the jar.

Environment variable: QUARKUS_OPENSHIFT_JAR_FILE_NAME

Show more

string

The directory where the native binary is added during the assemble phase. This is dependent on the S2I image and should be supplied if a non-default image is used.

Environment variable: QUARKUS_OPENSHIFT_NATIVE_BINARY_DIRECTORY

Show more

string

The resulting filename of the native binary in the S2I image. This option may be used if the selected S2I image uses a fixed name for the native binary.

Environment variable: QUARKUS_OPENSHIFT_NATIVE_BINARY_FILE_NAME

Show more

string

The build timeout.

Environment variable: QUARKUS_OPENSHIFT_BUILD_TIMEOUT

Show more

Duration

PT5M

The log level of OpenShift build log.

Environment variable: QUARKUS_OPENSHIFT_BUILD_LOG_LEVEL

Show more

fatal, error, warn, info, debug, trace

info

The image push secret to use for pushing to external registries. (see: https://cloud.redhat.com/blog/pushing-application-images-to-an-external-registry)

Environment variable: QUARKUS_OPENSHIFT_IMAGE_PUSH_SECRET

Show more

string

The build config strategy to use.

Environment variable: QUARKUS_S2I_BUILD_STRATEGY

Show more

binary, docker

binary

The base image to be used when a container image is being produced for the jar build. When the application is built against Java 21 or higher, registry.access.redhat.com/ubi8/openjdk-21:1.18 is used as the default. Otherwise registry.access.redhat.com/ubi8/openjdk-17:1.18 is used as the default.

Environment variable: QUARKUS_S2I_BASE_JVM_IMAGE

Show more

string

The base image to be used when a container image is being produced for the native binary build

Environment variable: QUARKUS_S2I_BASE_NATIVE_IMAGE

Show more

string

quay.io/quarkus/ubi-quarkus-native-binary-s2i:2.0

The JVM arguments to pass to the JVM when starting the application

Environment variable: QUARKUS_S2I_JVM_ARGUMENTS

Show more

list of string

Additional arguments to pass when starting the native application

Environment variable: QUARKUS_S2I_NATIVE_ARGUMENTS

Show more

list of string

The directory where the jar is added during the assemble phase. This is dependent on the S2I image and should be supplied if a non default image is used.

Environment variable: QUARKUS_S2I_JAR_DIRECTORY

Show more

string

/deployments/target/

The resulting filename of the jar in the S2I image. This option may be used if the selected S2I image uses a fixed name for the jar.

Environment variable: QUARKUS_S2I_JAR_FILE_NAME

Show more

string

The directory where the native binary is added during the assemble phase. This is dependent on the S2I image and should be supplied if a non-default image is used.

Environment variable: QUARKUS_S2I_NATIVE_BINARY_DIRECTORY

Show more

string

/home/quarkus/

The resulting filename of the native binary in the S2I image. This option may be used if the selected S2I image uses a fixed name for the native binary.

Environment variable: QUARKUS_S2I_NATIVE_BINARY_FILE_NAME

Show more

string

The build timeout.

Environment variable: QUARKUS_S2I_BUILD_TIMEOUT

Show more

Duration

PT5M

期間フォーマットについて

To write duration values, use the standard java.time.Duration format. See the Duration#parse() Java API documentation for more information.

数字で始まる簡略化した書式を使うこともできます:

  • 数値のみの場合は、秒単位の時間を表します。

  • 数値の後に ms が続く場合は、ミリ秒単位の時間を表します。

その他の場合は、簡略化されたフォーマットが解析のために java.time.Duration フォーマットに変換されます:

  • 数値の後に hms が続く場合は、その前に PT が付けられます。

  • 数値の後に d が続く場合は、その前に P が付けられます。

関連コンテンツ