diff --git a/docs/reference/module-types/maven-container.md b/docs/reference/module-types/maven-container.md index d3bd5d72ab..fbe991c3db 100644 --- a/docs/reference/module-types/maven-container.md +++ b/docs/reference/module-types/maven-container.md @@ -583,6 +583,14 @@ The JDK version to use. | Type | Required | | ---- | -------- | | `number` | No +### `module.mvnOpts[]` +[module](#module) > mvnOpts + +Options to add to the `mvn package` command when building. + +| Type | Required | +| ---- | -------- | +| `array[string]` | No ## Complete YAML schema @@ -648,4 +656,5 @@ module: env: {} jarPath: jdkVersion: 8 + mvnOpts: [] ``` diff --git a/garden-service/src/plugins/maven-container/maven-container.ts b/garden-service/src/plugins/maven-container/maven-container.ts index 2197844f6c..ba19bf207d 100644 --- a/garden-service/src/plugins/maven-container/maven-container.ts +++ b/garden-service/src/plugins/maven-container/maven-container.ts @@ -102,7 +102,7 @@ async function configure(params: ConfigureModuleParams) { const jdkVersion = mavenFields.jdkVersion! containerConfig.spec.buildArgs = { - JAR_PATH: mavenFields.jarPath!, + JAR_PATH: "app.jar", JDK_VERSION: jdkVersion.toString(), }