Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to view Jenkins workspace on a Pipeline job?

How can I view Jenkins workspace on a Pipeline job (it was called workflow job previously)? In a standard Job I could just go to the Job main page and view it by clicking on "Workspace".

like image 586
Ron Keidar Avatar asked Jun 11 '15 19:06

Ron Keidar


People also ask

Where can I find Jenkins workspace?

Default workspace location - It seems like the latest Jenkins has the default workspace in Jenkins\jobs[projectName]\workspace and is overwritten (or wiped if selected) for every build.

How do I change the workspace in Jenkins pipeline?

So if you wish to change the Jenkins workspace, all you've do is change the path of your JENKINS_HOME. For slave nodes, specify the default workspace on the slave machine in the slave configuration under Manage Jenkins > Manage Nodes > > Configure > Remote FS root.

What is my Jenkins workspace?

The workspace directory is where Jenkins builds your project: it contains the source code Jenkins checks out, plus any files generated by the build itself. This workspace is reused for each successive build.

How can I see Jenkins pipeline configuration?

Click New Item on your Jenkins home page, enter a name for your (pipeline) job, select Pipeline, and click OK. In the Script text area of the configuration screen, enter your pipeline syntax.


2 Answers

  1. Go to the Jenkins build
  2. On the left hand side click the Pipeline steps
  3. Then on the right click on the link that says "Allocate node : Start - (x min in block)"
  4. On the the left side click the workspace. Done!

The image below might help :

Workspace

Check out this link it shows how to get the workspace when you are using jenkins pipeline: https://www.selikoff.net/2016/07/10/workspace-jenkins-pipelines/

like image 141
sam Avatar answered Sep 20 '22 11:09

sam


Pending JENKINS-26138 it is possible albeit inconvenient. Click Pipeline Steps (in older versions, Running Steps) and select the block start for the node (or, rarely, ws) step which created the workspace you are interested in. (Unlike with a freestyle project, there might be zero or several such steps in a given build.) On that step page there will be a Workspace link.

like image 32
Jesse Glick Avatar answered Sep 21 '22 11:09

Jesse Glick