#查看jenkins镜像 docker search jenkins #安装jenkins docker pull jenkins/jenkins:lts #jenkins 挂载目录 mkdir -p /home/jenkins/workspace #启动jenkins docker run -uroot -d --restart=always -p 9001:8080 \ -v /home/jenkins/workspace/:/var/jenkins_home/workspace \ -v /var/run/docker.sock:/var/run/docker.sock \ -v /usr/local/maven/apache-maven-3.8.8:/usr/local/maven \ --name jenkins jenkins/jenkins:lts #-uroot 是以管理员身份登入容器查看密码 docker exec -it -uroot jenkins bash #jenkins ci/cd 插件 #Maven Integration #Publish Over SSH #Git docker cp /usr/local/java/jdk1.8.0_181/. jenkins:/usr/local/jdk8 docker cp /usr/local/maven/apache-maven-3.8.8/. jenkins:/usr/local/maven
参考链接:
https://blog.csdn.net/qq_51726114/article/details/134174736
https://blog.csdn.net/dontYouWorry/article/details/129007966
https://blog.csdn.net/qq_36858491/article/details/136525564
标签:部署,maven,csdn,usr,jenkins,docker,local From: https://www.cnblogs.com/huangkai00000/p/18374482