Skip to content
 
 

Repository files navigation

Java Base Docker Images

This is a repository for Java Docker base images used for running JVM applications.

You can find the images in our Docker Hub repository.

The Docker build files for these images are generated by fish-pepper, a sophisticated template system for generation Docker builds. fish-pepper allows the composition of various building blocks, so that parametrized Docker builds are easily possible.

The Java base images come in different flavours:

All images add the following features:

  • agent-bond is included which combines Jolokia and jmx_exporter
  • A startup script run-java.sh is included which transparently starts Java application provided as FAT-jar or traditionally with a bunch of jar dependencies.

How to use these images and what environment variables can be used are described in the associated README files.

Quick Start

If using nix and direnv, it will auto-setup a ready to use environment to start hacking quickly:

$ direnv allow

And after that:

$ just

It will display the list of all available commands and shortcuts:

just --list
Available recipes:
    build
    b                 # alias for `build`
    default           # Lists all available commands
    fish-pepper *ARGS
    fp *ARGS          # alias for `fish-pepper`
    fmt
    f                 # alias for `fmt`
    make
    m                 # alias for `make`

Otherwise, you'll need to install the following dependencies manually (and you can skip safely installing nix package manager):

List of available commands

For calling fish-pepper:

$ just fish-pepper <ARGS> # just fp <ARGS>

For rendering docker templates (alias of fish-pepper build):

$ just build # just b

For rendering and building docker templates using available docker daemon (alias of fish-pepper make):

$ just make # just m

For formatting source code with treefmt:

$ just fmt # just f

Differences with the original repository

There are some notable differences with upstream:

  • Inclusion of nix and direnv to have a reproducible dev environment.
  • Support for more OSes like Ubuntu and removal of Jboss one.
  • Support for JDK17.
  • Minor corrections to Dockerfiles suggested by hadolint.

If you detect any issues with the provided images, feel free to open an issue (also, a PR with the fix will be greatly appreciated!).

About

Java Base Images

Resources

Code of conduct

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages