Skip to content

Commit

Permalink
Merge pull request snyk#718 from snyk/chore/new-docker-images
Browse files Browse the repository at this point in the history
feat: new docker images for maven 3.6.1, gradle 5.4 with Java 11
  • Loading branch information
Mila Votradovec authored Aug 8, 2019
2 parents 64e248e + 45ffd12 commit 23a027e
Show file tree
Hide file tree
Showing 3 changed files with 106 additions and 0 deletions.
36 changes: 36 additions & 0 deletions docker/Dockerfile.gradle-5.4_java11
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
FROM openjdk:11-jdk-slim

MAINTAINER Snyk Ltd

RUN mkdir /home/node
WORKDIR /home/node

# Install gradle, node, cli
RUN apt-get update && \
apt-get install -y curl unzip && \
curl -L https://services.gradle.org/distributions/gradle-5.4-bin.zip -o gradle-5.4-bin.zip && \
unzip gradle-5.4-bin.zip -d /home/node/ && \
curl -sL https://deb.nodesource.com/setup_8.x | bash - && \
apt-get install -y nodejs jq npm && \
node -v && \
npm install --global snyk snyk-to-html && \
apt-get autoremove -y && \
apt-get clean && \
chmod -R a+wrx /home/node

ENV HOME /home/node
ENV M2 /home/node/.m2
ENV GRADLE_HOME=/home/node/gradle-5.4
ENV PATH=$PATH:$GRADLE_HOME/bin

# The path at which the project is mounted (-v runtime arg)
ENV PROJECT_PATH /project

COPY docker-entrypoint.sh .
COPY snyk_report.css .

ENTRYPOINT ["./docker-entrypoint.sh"]

# Default command is `snyk test`
# Override with `docker run ... snyk/snyk-cli <command> <args>`
CMD ["test"]
35 changes: 35 additions & 0 deletions docker/Dockerfile.maven-3.6.1
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
FROM openjdk:8-jdk-slim

MAINTAINER Snyk Ltd

RUN mkdir /home/node
WORKDIR /home/node

# Install maven, node, cli
RUN apt-get update && \
apt-get install -y curl git && \
curl -L -o apache-maven-3.6.1-bin.tar.gz https://www-eu.apache.org/dist/maven/maven-3/3.6.1/binaries/apache-maven-3.6.1-bin.tar.gz && \
tar -xvzf apache-maven-3.6.1-bin.tar.gz && \
rm -f apache-maven-3.6.1-bin.tar.gz && \
curl -sL https://deb.nodesource.com/setup_10.x | bash - && \
apt-get install -y nodejs jq && \
npm install --global snyk snyk-to-html && \
apt-get autoremove -y && \
apt-get clean && \
chmod -R a+wrx /home/node

ENV HOME /home/node
ENV M2 /home/node/.m2
ENV PATH /home/node/apache-maven-3.6.1/bin:$PATH

# The path at which the project is mounted (-v runtime arg)
ENV PROJECT_PATH /project

ADD docker-entrypoint.sh .
ADD snyk_report.css .

ENTRYPOINT ["./docker-entrypoint.sh"]

# Default command is `snyk test`
# Override with `docker run ... snyk/snyk-cli <command> <args>`
CMD ["test"]
35 changes: 35 additions & 0 deletions docker/Dockerfile.maven-3.6.1_java11
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
FROM openjdk:11-jdk-slim

MAINTAINER Snyk Ltd

RUN mkdir /home/node
WORKDIR /home/node

# Install maven, node, cli
RUN apt-get update && \
apt-get install -y curl git && \
curl -L -o apache-maven-3.6.1-bin.tar.gz https://www-eu.apache.org/dist/maven/maven-3/3.6.1/binaries/apache-maven-3.6.1-bin.tar.gz && \
tar -xvzf apache-maven-3.6.1-bin.tar.gz && \
rm -f apache-maven-3.6.1-bin.tar.gz && \
curl -sL https://deb.nodesource.com/setup_10.x | bash - && \
apt-get install -y nodejs jq && \
npm install --global snyk snyk-to-html && \
apt-get autoremove -y && \
apt-get clean && \
chmod -R a+wrx /home/node

ENV HOME /home/node
ENV M2 /home/node/.m2
ENV PATH /home/node/apache-maven-3.6.1/bin:$PATH

# The path at which the project is mounted (-v runtime arg)
ENV PROJECT_PATH /project

ADD docker-entrypoint.sh .
ADD snyk_report.css .

ENTRYPOINT ["./docker-entrypoint.sh"]

# Default command is `snyk test`
# Override with `docker run ... snyk/snyk-cli <command> <args>`
CMD ["test"]

0 comments on commit 23a027e

Please sign in to comment.