构建带maven环境的jenkins

FROM jenkinsci/blueocean:latest

#安装jdk
#ADD jdk-8u45-linux-x64.tar.gz /opt/jdk
#ENV JAVA_HOME /opt/jdk/jdk1.8.0_45
#ENV CLASSPATH $JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar
#ENV PATH $PATH:$JAVA_HOME/bin

##安装maven
ADD apache-maven-3.6.3-bin.tar.gz /opt/maven
ENV MAVEN_HOME /opt/maven/apache-maven-3.6.3
ENV PATH $PATH:$MAVEN_HOME/bin
posted @ 2022-05-03 09:55  紫川先生  阅读(27)  评论(0编辑  收藏  举报