In this video , Phil Webb describes how to turn on layering of a Spring Boot docker image built by build packs, by adding the layers enabled true configuration for the maven plugin. How do you configure the gradle plugin to do the same ? I can't see any reference to this in the reference manual for the gradle plugin.
It turns out you configure the bootRun task, not the bootBuildImage task, like so:
tasks.bootJar {
layered()
}
My question ended up being a duplicate of this one
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.