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

Add an ability to specify external GIT repository for scripts

      It would be sensible to add an ability to specify an external scripts GIT repo, not only GitHub one.
      We have a big collection of scripts, could not be shared either to everybody from open space or from organization. We have our own Gerrit, where these scripts are stored. It would be a great feature for us to be able to specify this repo as a source of scripts.

          [JENKINS-18862] Add an ability to specify external GIT repository for scripts

          can't you just push to the scriptler repo?

          Dominik Bartholdi added a comment - can't you just push to the scriptler repo?

          This would be useful for us too. Because of company policy, all source code must be stored in our company's Git server.

          Daniel Serodio added a comment - This would be useful for us too. Because of company policy, all source code must be stored in our company's Git server.

          Mike Brosnan added a comment -

          If this plugin allowed access to use a different external repo, I believe that enterprise users of Jenkins would still contribute some scripts to github and scriptler, but the main body of scripts would be from an internal repo.

          If scriptler is not updated to allow an internal catalog, then teams will just fork the code to build their own internal versions of the plugin

          Mike Brosnan added a comment - If this plugin allowed access to use a different external repo, I believe that enterprise users of Jenkins would still contribute some scripts to github and scriptler, but the main body of scripts would be from an internal repo. If scriptler is not updated to allow an internal catalog, then teams will just fork the code to build their own internal versions of the plugin

          Ed Mangual added a comment -

          I have the same requirements as the users stated above. We would like for this plugin to have the ability to point to our own repo for groovy scripts.

          Ed Mangual added a comment - I have the same requirements as the users stated above. We would like for this plugin to have the ability to point to our own repo for groovy scripts.

          just to be clear, you would like to have an inhouse catalog (1) - a list of scripts that can be imported into individual jenkins instances via scriptler?

          (1) https://wiki.jenkins-ci.org/display/JENKINS/Scriptler+Plugin#ScriptlerPlugin-Catalogs

          Dominik Bartholdi added a comment - just to be clear, you would like to have an inhouse catalog (1) - a list of scripts that can be imported into individual jenkins instances via scriptler? (1) https://wiki.jenkins-ci.org/display/JENKINS/Scriptler+Plugin#ScriptlerPlugin-Catalogs

          Ed Mangual added a comment -

          That is correct.

          Ed Mangual added a comment - That is correct.

          imod, can I launch this "Import" step through a groovy script as well?

          That way, I could have a job that listens to my in-house git repository, and imports all new/changed scripts on every push. Which would be as good as specifiying an external GIT repo.

          Of course, if I manage the scripts externally, a way to forbid direct changes through the Jenkins UI would be necessary, but this is the next step

          Hakan Tandogan added a comment - imod , can I launch this "Import" step through a groovy script as well? That way, I could have a job that listens to my in-house git repository, and imports all new/changed scripts on every push. Which would be as good as specifiying an external GIT repo. Of course, if I manage the scripts externally, a way to forbid direct changes through the Jenkins UI would be necessary, but this is the next step

          hakan no sorry, that's not possible - but there is an extension point you can implement to add a new catalog: org.jenkinsci.plugins.scriptler.share.ScriptInfoCatalog

          Dominik Bartholdi added a comment - hakan no sorry, that's not possible - but there is an extension point you can implement to add a new catalog: org.jenkinsci.plugins.scriptler.share.ScriptInfoCatalog

          Dax Games added a comment - - edited

          Useful for us too.

          My Jenkins is authenticated and authorized using SAML and I cannot figure out how to push/pull to Scriptler Git repo on a Jenkins server. Maybe you could share some insight.

          To be clear:

          1. I would like to have a remote Git Repo that is AUTOMATICALY cloned/pulled to the Jenkins server possibly periodically or on repo change.
          2. Scripts should be immediately available for use via the scriptler interface.
            a. I do not want to have to manually click on 1-[n] scripts to import them one at a time.
          3. Should be configurable via JCASC.

          Plus centralization of the scripts is better than managing a repo on EVERY Jenkins server.

          Dax Games added a comment - - edited Useful for us too. My Jenkins is authenticated and authorized using SAML and I cannot figure out how to push/pull to Scriptler Git repo on a Jenkins server. Maybe you could share some insight. To be clear: I would like to have a remote Git Repo that is AUTOMATICALY cloned/pulled to the Jenkins server possibly periodically or on repo change. Scripts should be immediately available for use via the scriptler interface. a. I do not want to have to manually click on 1- [n] scripts to import them one at a time. Should be configurable via JCASC. Plus centralization of the scripts is better than managing a repo on EVERY Jenkins server.

            domi Dominik Bartholdi
            joesephz Joe Zeldin
            Votes:
            9 Vote for this issue
            Watchers:
            13 Start watching this issue

              Created:
              Updated: