Inconsistency in "Kubernetes Container Lifecycle" documentation after Spring Boot 3.4.0 upgrade #43830
Open
Description
Or, maybe, not exactly inconsistency but now it's a bit misleading...
In the Kubernetes Container Lifecycle there is a suggestion to use preStop handler like this: command: ["sh", "-c", "sleep 10"]
Problem is that by default Spring Boot paketo images from now on use paketobuildpacks/builder-jammy-java-tiny
image, which does not have any shell.
So, either a new recipe should be suggested or a word of warning should say that for default spring boot images that won't work anymore.
As a suggestion - maybe include "sleep" command into the image, so something like this would work?
lifecycle:
preStop:
exec:
command:
- sleep
- 60