Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-75143

No oportunity to install LFS when using pipeline

      When enabling "Git LFS pull after checkout" and pipeline file, there is no oportunity to install git LFS before checking out the repository. (https://plugins.jenkins.io/git/#plugin-content-git-lfs-pull-after-checkout)

      That causes the error "hudson.plugins.git.GitException: Command "git lfs pull origin" returned status code 1: stdout: stderr: git: 'lfs' is not a git command."

      Maybe an additional behaviour like "Pre SCM BuildStep" would be enough to achieve this where the user can enter the command "git lfs install".

          [JENKINS-75143] No oportunity to install LFS when using pipeline

          Mark Waite added a comment -

          Closing as a duplicate of JENKINS-68555.

          Other alternatives include:

          • Run git lfs install in the virtual machine or container image of the agent before Jenkins connects to it. AWS and others have the concept of a cloud-init script that can perform that type of operation. Since `git lfs install` is a one time operation, that seems like the most logical step
          • Run git lfs install in the scripted Pipeline before calling checkout scm
          • Disable default checkout in declarative Pipeline and run git lfs install before calling checkout scm
          • Create a label verifier that runs git lfs install when the agent connects, before any job runs

          Mark Waite added a comment - Closing as a duplicate of JENKINS-68555 . Other alternatives include: Run git lfs install in the virtual machine or container image of the agent before Jenkins connects to it. AWS and others have the concept of a cloud-init script that can perform that type of operation. Since `git lfs install` is a one time operation, that seems like the most logical step Run git lfs install in the scripted Pipeline before calling checkout scm Disable default checkout in declarative Pipeline and run git lfs install before calling checkout scm Create a label verifier that runs git lfs install when the agent connects, before any job runs

            Unassigned Unassigned
            cassiolandim Cassio
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: