1

I have the same problem as in: Jenkins multibranch - how to scan branches where jenkinsfile is placed on a submodule?

Note that both repositories are placed on a private gitlab server and they are set as private. However i've no problem in checkout both interdependently on Jenkins.

I have my jenkinsfile for a branch placed on a submodule like so:

main/
   ...
   submodule/ -> submodule
      jenkinsfile

But i'm unable to run a Multibranch pipeline. The scan cannot detect the jenkinfile:

Checking branches...
  Checking branch main
      ‘submodule/jenkinsfile’ not found
    Does not meet criteria
Processed 1 branches

I've tried all the options on the following thread: Git submodules not updating in Jenkins build

But none work.

Versions:

  • jenkins version: Jenkins 2.332.3
  • Git plugin Version 4.11.5 GitHub
  • Branch Source Plugin Version 1677.v731f745ea_0cf

As anyone figure out the solution to this? Thanks

greenv
  • 21
  • 7

1 Answers1

1

I've managed to resolve my issues based on this thread: https://devops.stackexchange.com/questions/9243/is-there-a-way-to-use-a-jenkinsfile-from-a-git-submodule-in-a-multibranch-pipeli

i've installed this plugin: https://plugins.jenkins.io/remote-file/ and it solved my issues.

greenv
  • 21
  • 7