Skip to content

Optimized Docker image (modified Dockerfile) #1919

@ghrlgv

Description

@ghrlgv

As I have limited compute and storage resources, I use docker when possible.

The included original Dockerfile creates an image that builds the java executable when running the image (starting the app container) and includes the full JDK environment. The following Dockerfile generates a image that is half the size, includes only a runtime version of java (jre), uses a slim Debian base image and doesn't create the java executable when the container is started. Hence, it uses less resources and is speedier.

Feel free to use the attached Dockerfile and adjust it as needed (rename it to Dockerfile and use docker compose build).

Dockerfile.txt

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions