cloudnet-compose/worker
Sebastiaan van Stijn 8b6432d58d
Optimize java-worker image
This patch optimizes the java-worker image;

- Use multi-stage build to separate the build-stage from the "deploy" stage
- Switch to the official Maven image, instead of manual installation of Maven.
  The official Maven image is also based on the `openjdk` repository on Docker
  Hub, which replaces the (now deprecated) `java` repository.
- Use `COPY` instead of `ADD` to follow best-practice
- Add `-XX:+UnlockExperimentalVMOptions -XX:+UseCGroupMemoryLimitForHeap` arguments
  so that JAVA will take memory-limits into account
- Use a JRE base image for the final build-stage

This change brings the size of the final image down from 184MB to 87MB

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2018-01-04 12:39:17 +01:00
..
src Merge pull request #89 from oherrala/redisconn 2017-11-29 11:39:59 -08:00
Dockerfile FEATURED: .NET 2.0.0 SDK for Worker 2017-10-02 11:50:53 +07:00
Dockerfile.j Optimize java-worker image 2018-01-04 12:39:17 +01:00
pom.xml Restore Java worker 2016-06-30 13:35:10 -07:00