Hello. I`m use spring-boot-maven-plugin 2.3.2.RELEASE . How can stating my app with command line arguments? I need pass to main() my args, but not see in docs how can i do it.

      <plugin>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-maven-plugin</artifactId>
        <version>2.3.2.RELEASE</version>
        <configuration>
          <mainClass>org.orglot.gosloto.ShopApp</mainClass>
          <image>
            <name>docker.io/${project.artifactId}:${project.version}</name>
            <env>
              <BP_JVM_VERSION>14</BP_JVM_VERSION>
              <BPL_JVM_THREAD_COUNT>101</BPL_JVM_THREAD_COUNT>
              <BP_BOOT_NATIVE_IMAGE_BUILD_ARGUMENTS>one two</BP_BOOT_NATIVE_IMAGE_BUILD_ARGUMENTS>
              <JAVA_OPTS>-Xms500m</JAVA_OPTS>
            </env>
          </image>
          <skip>false</skip>
        </configuration>
      </plugin>

in output i see


INFO]     [creator]     Paketo Executable JAR Buildpack 2.1.1
[INFO]     [creator]       https://github.com/paketo-buildpacks/executable-jar
[INFO]     [creator]       Launch Configuration:
[INFO]     [creator]         $JAVA_OPTS  -Xms500m  the flags passed to the JVM process at launch
[INFO]     [creator]       Process types:
[INFO]     [creator]         executable-jar: java -cp "${CLASSPATH}" ${JAVA_OPTS} org.springframework.boot.loader.JarLauncher
[INFO]     [creator]         task:           java -cp "${CLASSPATH}" ${JAVA_OPTS} org.springframework.boot.loader.JarLauncher
[INFO]     [creator]         web:            java -cp "${CLASSPATH}" ${JAVA_OPTS} org.springframework.boot.loader.JarLauncher
[INFO]     [creator]     

what mean java not passed arguments ?

Comment From: scottfrederick

The values passed in the env block are used by the builder when creating an image, and are not provided to the application at runtime. This behavior is determined by the applicable buildpacks (e.g. https://github.com/paketo-buildpacks/executable-jar), not by Spring Boot.

There are instructions for passing args to a containerized app with Docker and Kubernetes.

If you have any further questions, please follow up on Stack Overflow or Gitter. As mentioned in the guidelines for contributing, we prefer to use GitHub issues only for bugs and enhancements.