This repository was archived by the owner on Oct 15, 2023. It is now read-only.

Description
The currently-built JanusGraph Docker images are way too large. While recent releases are on the order of 260-270MB, the built containers are much larger.
Compare:
| Version |
Release zip size |
Docker image size |
| 0.2.2 |
276 MB |
702 MB |
| 0.2.3 |
276 MB |
675 MB |
| 0.3.1 |
261 MB |
647 MB |
| 0.3.2 |
261 MB |
N/A (not published yet) |
It may be because the current Docker images are built using the base image openjdk:8-jdk but we don't need the JDK for running JanusGraph, that's what we need to compile it. Thus, we can simply use the JRE instead of the JDK for running it, so we can start using openjdk:8-jre.
Further, we can get rid of even more unneeded support in the base image by switching to openjdk:8-jre-slim which should be sufficient for running JanusGraph.
These image versions are listed on OpenJDK image files.
For details on these image versions, see this SO answer which breaks down the various types of OpenJDK Docker image base images.