Checkout Jenkins Pipeline Git SCM with credentials?

后端 未结 6 1694
情深已故
情深已故 2020-12-04 08:20

I was following this tutorial:

node {
  git url: \'https://github.com/joe_user/simple-maven-project-with-tests.git\'
  ...
}

However it doe

6条回答
  •  野趣味
    野趣味 (楼主)
    2020-12-04 09:08

    It solved for me using

    checkout scm: ([
                        $class: 'GitSCM',
                        userRemoteConfigs: [[credentialsId: '******',url: ${project_url}]],
                        branches: [[name: 'refs/tags/${project_tag}']]
                ])
    

提交回复
热议问题