docker版jenkins全局工具配置maven
docker run --name myjenkins \
-d -p 8080:8080 \
-p 50000:50000 \
-v /home/wyt/jenkins_home:/var/jenkins_home \
-v /usr/local/apache-maven-3.6.3:/usr/local/maven \
-v /usr/local/allure-2.17.2:/usr/local/allure-2.17.2 \
--env JAVA_OPTS="-Xms256m -Xmx512m -Xss1024K -XX:PermSize=128m -XX:MaxPermSize=256m" jenkins/jenkins
报错:/usr/local/maven is not a directory on the Jenkins controller (but perhaps it exists on some agents)
解决办法:修改启动命令
docker run --name myjenkins \
-d -p 8080:8080 \
-p 50000:50000 \
-v /home/wyt/jenkins_home:/var/jenkins_home \
-v /usr/local/apache-maven-3.6.3:/usr/local/apache-maven-3.6.3 \
-v /usr/local/allure-2.17.2:/usr/local/allure-2.17.2 \
--env JAVA_OPTS="-Xms256m -Xmx512m -Xss1024K -XX:PermSize=128m -XX:MaxPermSize=256m" jenkins/jenkins