Skip to content

gustafc/jfokus-2023-examples

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 

Repository files navigation

jfokus-2023-examples

This repo has some examples and links relevant to my talk Faster builds and slimmer images with Docker multistage builds at the 2023 installment of the JFokus conference.

Bug in the Jfokus presentation

If you watched the presentation you may have noticed that the demo of --cache-from didn't work out the way the presenter had hoped 🙂

This was because you need to set the environment variable DOCKER_BUILDKIT for this feature to work:

# On *nix shells:
export DOCKER_BUILDKIT=1

# On Windows/cmd:
set DOCKER_BUILDKIT=1

Once this is set, you can use any image built with --build-arg BUILDKIT_INLINE_CACHE=1 can be used as a target for --cache-from.

The examples

  • example-node-app is a very full-featured example building a React app and packaging it in an nginx container. This is the project I demo in the talk.
  • example-mvn-app is a simple approach to a cache-friendly and fairly "feature complete" Maven build - you can build a container running a simple Spring Boot app, and export test reports.

Links

  • Mejsla - where I work
  • Dockerfile reference - this document probably has the answers to most technical questions you have about your Docker builds.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages