Dockerfile 678 B

123456789101112131415161718192021
  1. FROM docker.shemic.com/dev/java:latest
  2. MAINTAINER Rabin "https://github.com/shemic"
  3. ARG SCALA_VERSION
  4. ARG SCALA_HOME
  5. ENV SCALA_VERSION=${SCALA_VERSION:-2.12.2}
  6. ENV SCALA_HOME=${SCALA_HOME:-/opt/scala}
  7. ENV PATH=${PATH}:${JAVA_HOME}/bin:${JAVA_HOME}/sbin:${SCALA_HOME}/bin
  8. RUN java -version 2>&1 | grep version | sed -e 's/^openjdk version /JAVA_VERSION=/' > $JAVA_HOME/release
  9. RUN apk add --no-cache --update curl && \
  10. curl -O https://downloads.lightbend.com/scala/$SCALA_VERSION/scala-$SCALA_VERSION.tgz && \
  11. tar -xf scala-$SCALA_VERSION.tgz && \
  12. rm scala-$SCALA_VERSION.tgz && \
  13. mv scala-$SCALA_VERSION $SCALA_HOME && \
  14. apk del curl
  15. ENTRYPOINT ["sh"]