How to avoid source checking on master node with jenkins pipe

I want to define my assemblies using the Jenkins 2 pipeline function, and I want this configuration to be loaded from sources in Jenkinsfile . However, I don't want to clutter my master node with a workspace.

Ideally, I could indicate that the job pipeline is designed to run a given type of node, but this is not possible.

I see two alternatives:

  • use the dedicated repository that stores the jenkins job configuration.
  • use git debugging strategy (shallow + sparse).

Did I miss something? What would be the best practice?

+6
source share
2 answers

There, the problem with Jenkins that claims this is now fixed, and only the Jenkinsfile wizard should be checked on the host: https://issues.jenkins-ci.org/browse/JENKINS-33273

(At the moment, this does not work for me.)

+2
source

I think you can use the Jenkinsfile. But avoid using the 'git checkout' step The workspace is not acceptable for the jenkins web interface. This way you can use jenkinsfile to manage your builds.

0
source

All Articles