Java in Container - Best Practicies for containerized Java Apps
summary
Covers concrete fixes and tools: use exec form ENTRYPOINT so SIGTERM reaches the JVM, handle graceful shutdown instead of kill -9, and prefer multi-stage builds with unpacked fat JAR into lib/classes layers to make rebuild diffs kilobytes instead of re-pushing ~40 MB and to cut an image from ~881 MB to ~124 MB. Recommends Java 11 (or Fabric8 run-java.sh for older JDKs), pick Alpine/OpenJDK carefully, run as non-root user, and use scanners like Clair plus jlink/GraalVM/jib for smaller, faster images.
AI-written summary · about
chapters (12)
- 0:00Start
- 5:54First Docker File
- 15:12Java Runtime
- 22:31Java Modularity
- 24:21Unpacking of Jar
- 27:10Pros
- 28:24Multistage
- 29:49Process of Unpacking Jars
- 30:24Java Ergonomics
- 36:32Security
- 38:18Container as a Read-Only
- 40:56What's Google Deep
related talks
49mJava and Containers Make it Awesome
46mJava in a World of Containers
01h 01mDistilling Java Containers for Kubernetes
25mCommit to Excellence - Java in Containers
48mJava in Containers - Part Deux
56mBeyond the Container: Compact and Fast Images With and Without Native Image
47mLegal JVM Doping in Your Containers
42mContainers & Java: What I wish I have been told!
