Failed to perform checkout on agent: /usr/local/bin/git -c core.askpass=/Users/user/Documents/TeamCity/buildAgent/temp/buildTmp/pass -c credential.helper= -c credential.helper=/Users/user/Documents/TeamCity/buildAgent/temp/buildTmp/credHelper.sh checkout -q -f release/2 command failed.
exit code: 128
stderr: git-lfs filter-process: git-lfs: command not found
fatal: the remote end hung up unexpectedly
`on the Agent side
TEAMCITY_GIT_PATH /usr/local/bin/git
TEAMCITY_GIT_VERSION 2.38.0.0
TeamCity Professional 2022.10 (build 116751)`
user@iMac-User-3 ~ % which git-lfs
/usr/local/bin/git-lfs
Can someone suggest, how to resolve?
Top comments (1)
To fix the "Build Agent doesn't support git-lfs" error in TeamCity, you will need to make sure that the
git-lfs
command is available to the build agent. This can be accomplished by installing thegit-lfs
command on the build agent machine, and ensuring that it is in the system PATH so that it can be executed by the build agent.Here is an example of how you might do this:
Install the
git-lfs
command on the build agent machine. This can typically be done by running a command likeapt-get install git-lfs
(on Ubuntu) orbrew install git-lfs
(on macOS).Verify that the
git-lfs
command is in the system PATH. You can do this by running thewhich git-lfs
command on the build agent machine, which should return the path to thegit-lfs
command if it is installed and available in the PATH.If the
git-lfs
command is not in the PATH, you can add it by modifying thePATH
environment variable on the build agent machine. For example, you might add a line likePATH=$PATH:/usr/local/bin
to the/etc/environment
file, which would add the/usr/local/bin
directory to the system PATH.Once the
git-lfs
command is installed and available in the PATH on the build agent machine, you should be able to run a build in TeamCity without encountering the "Build Agent doesn't support git-lfs" error. This will allow the build agent to access and use thegit-lfs
command when checking out code from a Git repository that uses Git LFS.I'm an experimental help bot that leverages ChatGPT. As such, the answers I provide may be incorrect, incomplete, or even nonsensical. I am not associated with OpenAI.
Please reply to my comment(s) with your own corrections and feedback.