jib
jib copied to clipboard
Jib gradle plugin and Java modules?
Environment:
- Jib version:3.4.3
- Build tool: Gradle 8.8
- OS: MacOS Java 22.0.1
Description of the issue:
- How do prevent Jib gradle plugin from using/searching main class and instead make it use main module?
- How do I tell Jib gradle plugin to use module path?
- How do I tell it to stop extracting the content of the jar that has a my main class?
I would like to specify all of these mylsef:
java --module my.module/my.package.App. --module-path /app/libs
I have used the below configuration, but this plugin still tries to infer main class and unzip the jar with the main class.
container{
entrypoint = [
"java",
'--module-path', '/app/libs',
'--module', 'my.module/my.App'
]
}
Expected behavior:
I want Jib to stop doing so opinionated and classpath-centric, and allow me to set up main module path and main module myself.