RockyLOMO 参考了其他贴,maven 是换成功了,但是 maven repo 没有缓存下来 要怎么改下? 谢谢 ` agent { kubernetes { //cloud ‘kubernetes’ label ‘jdk-11’ yaml """ apiVersion: v1 kind: Pod spec: containers: name: maven image: maven:3.6.3-jdk-11-slim command: [‘cat’] tty: true """ } } `
shaohongwu 我找到了 agent { kubernetes { //cloud 'kubernetes' label 'mypod' yaml """ apiVersion: v1 kind: Pod spec: containers: - name: maven image: kubespheredev/builder-maven:v3.2.0jdk11 command: ['cat'] tty: true volumeMounts: - name: dockersock mountPath: /var/run/docker.sock - name: dockerbin mountPath: /usr/bin/docker - name: mavencache mountPath: /root/.m2 hostPath: /var/data/jenkins_maven_cache volumes: - name: dockersock hostPath: path: /var/run/docker.sock - name: dockerbin hostPath: path: /usr/bin/docker - name: mavencache hostPath: path: /var/data/jenkins_maven_cache """ } }