From c17d298bf11470d59cb91c2dea679ade91d1bf45 Mon Sep 17 00:00:00 2001 From: Jack Low Date: Tue, 7 Aug 2018 17:15:01 +1000 Subject: [PATCH] Change openjdk:latest to openjdk:8 because the latest version of openjdk has moved to Java 10, which is not fully compatible with Scala. (#1147) --- .../scala/com/typesafe/sbt/packager/docker/DockerPlugin.scala | 2 +- src/sbt-test/docker/override-commands/build.sbt | 2 +- src/sphinx/formats/docker.rst | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/scala/com/typesafe/sbt/packager/docker/DockerPlugin.scala b/src/main/scala/com/typesafe/sbt/packager/docker/DockerPlugin.scala index abd3a4ed6..8db845a30 100644 --- a/src/main/scala/com/typesafe/sbt/packager/docker/DockerPlugin.scala +++ b/src/main/scala/com/typesafe/sbt/packager/docker/DockerPlugin.scala @@ -66,7 +66,7 @@ object DockerPlugin extends AutoPlugin { override def projectConfigurations: Seq[Configuration] = Seq(Docker) override lazy val projectSettings: Seq[Setting[_]] = Seq( - dockerBaseImage := "openjdk:latest", + dockerBaseImage := "openjdk:8", dockerExposedPorts := Seq(), dockerExposedUdpPorts := Seq(), dockerExposedVolumes := Seq(), diff --git a/src/sbt-test/docker/override-commands/build.sbt b/src/sbt-test/docker/override-commands/build.sbt index be1718124..07ac65650 100644 --- a/src/sbt-test/docker/override-commands/build.sbt +++ b/src/sbt-test/docker/override-commands/build.sbt @@ -9,7 +9,7 @@ maintainer := "Gary Coady " dockerUpdateLatest := true dockerCommands := Seq( - Cmd("FROM", "openjdk:latest"), + Cmd("FROM", "openjdk:8"), Cmd("LABEL", s"""MAINTAINER="${maintainer.value}""""), ExecCmd("CMD", "echo", "Hello, World from Docker") ) diff --git a/src/sphinx/formats/docker.rst b/src/sphinx/formats/docker.rst index 1712ea26e..077e9e887 100644 --- a/src/sphinx/formats/docker.rst +++ b/src/sphinx/formats/docker.rst @@ -243,7 +243,7 @@ In your sbt console type .. code-block:: bash > show dockerCommands - [info] List(Cmd(FROM,openjdk:latest), Cmd(LABEL,MAINTAINER=Your Name ), ...) + [info] List(Cmd(FROM,openjdk:8), Cmd(LABEL,MAINTAINER=Your Name ), ...) @@ -311,7 +311,7 @@ Now let's start adding some Docker commands. import com.typesafe.sbt.packager.docker._ dockerCommands := Seq( - Cmd("FROM", "openjdk:latest"), + Cmd("FROM", "openjdk:8"), Cmd("LABEL", s"""MAINTAINER="${maintainer.value}""""), ExecCmd("CMD", "echo", "Hello, World from Docker") )