[英]Jenkins Pipeline: git-lfs: command not found
I have got a Jenkins Pipeline Job configured to run a script from Git version control.我有一个 Jenkins 管道作业配置为从 Git 版本控制运行脚本。 I have given a repository path but it failing at checkout with git lfs command not found.
我已经给出了一个存储库路径,但它在结帐时使用 git lfs 命令未找到。
[Pipeline] End of Pipeline
hudson.plugins.git.GitException: Command "git checkout -f 0dac40f9a4f8908d177e319b2742908018663eb1" returned status code 128:
stdout:
stderr: git-lfs smudge -- 'testlfs.txt': git-lfs: command not found
error: external filter git-lfs smudge -- %f failed -1
error: external filter git-lfs smudge -- %f failed
fatal: testlfs.txt: smudge filter lfs failed
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2372)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$1000(CliGitAPIImpl.java:80)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$9.execute(CliGitAPIImpl.java:2681)
Caused: hudson.plugins.git.GitException: Could not checkout 0dac40f9a4f8908d177e319b2742908018663eb1
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$9.execute(CliGitAPIImpl.java:2705)
at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1195)
at org.jenkinsci.plugins.workflow.steps.scm.SCMStep.checkout(SCMStep.java:124)
at org.jenkinsci.plugins.workflow.steps.scm.SCMStep$StepExecutionImpl.run(SCMStep.java:93)
at org.jenkinsci.plugins.workflow.steps.scm.SCMStep$StepExecutionImpl.run(SCMStep.java:80)
at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Finished: FAILURE
How can I resolve this issue?我该如何解决这个问题? Please help!
请帮忙!
This is bug reported JENKINS-52857 and workaround was created manually link这是JENKINS-52857报告的错误,解决方法是手动创建的链接
ln -s /usr/local/bin/git-lfs /usr/local/Cellar/git/2.21.0/libexec/git-core/git-lf
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.