【发布时间】:2020-05-22 10:36:07
【问题描述】:
我的 github 存储库中的 Jenkins 文件用于 Jenkins 主/从环境。 我需要在远程 Jenkins 从服务器上执行测试命令。 在我的声明式管道中,代理的调用方式如下:
stage("Testautomation") {
agent { label 'test-device' }
steps {
bat '''
@ECHO ON
ECHO %WORKSPACE%
... '''
}
}
在 Jenkins 甚至可以执行远程命令之前,它就开始从版本控制中检出。 Jenkins Master 上的结帐没有问题并且工作正常。但是在这个 Jenkins Slave 上,我总是收到这个错误消息。
using credential github-enterprise:...
> git rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repository
> git config remote.origin.url https://...git # timeout=10
Fetching upstream changes from https://...git
> git --version # timeout=10
using GIT_ASKPASS to set credentials GitHub Enterprise Access Token
> git fetch --tags --force --progress --depth=1 -- https://...git +refs/heads/development:refs/remotes/origin/development # timeout=120
Checking out Revision ... (development)
> git config core.sparsecheckout # timeout=10
> git checkout -f ...
Could not checkout ...
【问题讨论】: