From 944cc2b0d8a653ecff6d836286ac831fbfab8955 Mon Sep 17 00:00:00 2001 From: Olafur Pall Geirsson Date: Mon, 30 Mar 2020 20:33:20 +0000 Subject: [PATCH] Add dockerfile from #1829 --- Dockerfile | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000000..1bcbeb6365 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,16 @@ +FROM openjdk:8 +ARG SCALAFMT_VERSION=2.4.2 +ARG SCALAFMT_INSTALL_LOCATION=/usr/local/bin/scalafmt +RUN set -ex \ + && apt-get update -y \ + && rm -rf /var/lib/apt/lists/* \ + && echo insecure > "$HOME/.curlrc" \ + && curl -Lo coursier https://git.io/coursier-cli \ + && chmod u+x coursier \ + && ./coursier bootstrap "org.scalameta:scalafmt-cli_2.12:$SCALAFMT_VERSION" \ + -r sonatype:snapshots \ + -o "$SCALAFMT_INSTALL_LOCATION" \ + --main org.scalafmt.cli.Cli \ + && rm -f coursier \ + && scalafmt --version +CMD ["/usr/local/bin/scalafmt"]