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

Add configuration field to set additional config options

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Minor Minor
    • git-plugin
    • None

      In our environment we have to clone from a server via https. This server has self-signed certificate that makes it necessary to set the global git sslVerify config option to false.

      It would be nice if we can set this option per job in the git plugin that adds the option to the clone command: "-c sslVerify=false".

          [JENKINS-34223] Add configuration field to set additional config options

          Daniel Black added a comment -

          I'd like to set submodule.common.url

          I have git mirror of a github repo that is being built in numerous ways. This upstream git repo has a large submodule which I've also mirrored. I don't want to pollute the mirror by changing its submodule configuration.

          Daniel Black added a comment - I'd like to set submodule.common.url I have git mirror of a github repo that is being built in numerous ways. This upstream git repo has a large submodule which I've also mirrored. I don't want to pollute the mirror by changing its submodule configuration.

          I'd like to set gc.auto to 0 to avoid automatic GC. We had a situation where the GC was failing, so every single checkout of our pipeline scripts took many minutes to complete.

          Dominic Hargreaves added a comment - I'd like to set gc.auto to 0 to avoid automatic GC. We had a situation where the GC was failing, so every single checkout of our pipeline scripts took many minutes to complete.

          Hello,

          I am facing a similar problem. We're using a Windows slave and our repository contains files with long path so we have to use "core.longpaths=true" to be able to clone the repo.

          I don't see any way to do this with the current plugin implementation.

          The possibility to add custom additional configuration options would allow us to deal with that and other scenario that cannot be dealt with the plugin existing options. I would raise the priority of this issue.

          Regards

          Lionel Cabasson added a comment - Hello, I am facing a similar problem. We're using a Windows slave and our repository contains files with long path so we have to use "core.longpaths=true" to be able to clone the repo. I don't see any way to do this with the current plugin implementation. The possibility to add custom additional configuration options would allow us to deal with that and other scenario that cannot be dealt with the plugin existing options. I would raise the priority of this issue. Regards

          Heiko Thiery added a comment -

          Is there any conclusion on that? how can I per job basis change the git behavior?

          Has anyone a glue on setting sslVerify option?

          Heiko Thiery added a comment - Is there any conclusion on that? how can I per job basis change the git behavior? Has anyone a glue on setting sslVerify option?

          Yoerg added a comment -

          I think it'd be helpful to allow setting arbitrary git options before fetch. I'd like to set submodule.<name>.active to false for a submodule I'm not interested in. My current workaround is setting it in the pipeline:

          options {skipDefaultCheckout true}
          tools {git 'git'}
          steps {
              sh('git init')
              sh('git config submodule.testutils.active false')
              checkout scm
              // ...
          

          Yoerg added a comment - I think it'd be helpful to allow setting arbitrary git options before fetch. I'd like to set submodule.<name>.active to false for a submodule I'm not interested in. My current workaround is setting it in the pipeline: options {skipDefaultCheckout true } tools {git 'git' } steps { sh( 'git init' ) sh( 'git config submodule.testutils.active false ' ) checkout scm // ...

            Unassigned Unassigned
            hthiery Heiko Thiery
            Votes:
            4 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated: