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

Support workspaces for Pipeline jobs

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      ExecutorStep adds a WorkspaceAction to track the fact that the flow build used a workspace, and if you navigate the flow graph UI you can get to a workspace browser, but there is not much more than that available. Need:

      • Analogue of noWorkspace.jelly in case a workspace cannot be loaded
      • Nicer DirectoryBrowserSupport.title: WorkflowRun.getFullDisplayName, computer, path, ...
      • Functionality similar to doDoWipeOutWorkspace, though see JENKINS-4646 and related issues
      • FlowNodeViewColumn or other way of seeing a list of workspaces for a build (or for the last build of the project)

        Attachments

          Issue Links

            Activity

            Hide
            jglick Jesse Glick added a comment -

            Filed PR with a basic display for classic UI. 2015-09-11 comments, as well as some miscellaneous fixes such as adding a wipe out workspace link, need to be refiled as separate issues, but I think this captures the most common and obvious request.

            Show
            jglick Jesse Glick added a comment - Filed PR with a basic display for classic UI. 2015-09-11 comments, as well as some miscellaneous fixes such as adding a wipe out workspace link, need to be refiled as separate issues, but I think this captures the most common and obvious request.
            Hide
            dnusbaum Devin Nusbaum added a comment -

            A way to easily view all of the workspaces for a specific build (the fourth bullet point in the description) was just added in version 2.24 of Pipeline Supporting APIs Plugin as a sidebar link named Workspaces on the build page.

            Show
            dnusbaum Devin Nusbaum added a comment - A way to easily view all of the workspaces for a specific build (the fourth bullet point in the description) was just added in version 2.24 of Pipeline Supporting APIs Plugin as a sidebar link named Workspaces on the build page.
            Hide
            monger39 David Riemens added a comment -

            Is there now a means to get the "workspace URL of multi branch pipeline jenkins projects" programmatically ? Such that I can:

            • add it into an email
            • expose it even within the job itself
              in the tests we are running I want to print an URL to the workspace for failing tests.

            Yes, I can navigate by hand to the workspace via the pipeline steps, but that is very cumbersome with 8 (or more) parallel branches.
            I've even added a  hard-code lookup table in my script, but that breaks as soon as I start multiple of the same jobs.

            NB: when I hover the mouse over the "Allocate node : Start" message, I do get a popup with "ID: 71" or so. All I need is that ID number within my "node {}" block ..

            someone please,,,

            Show
            monger39 David Riemens added a comment - Is there now a means to get the "workspace URL of multi branch pipeline jenkins projects" programmatically ? Such that I can: add it into an email expose it even within the job itself in the tests we are running I want to print an URL to the workspace for failing tests. Yes, I can navigate by hand to the workspace via the pipeline steps, but that is very cumbersome with 8 (or more) parallel branches. I've even added a  hard-code lookup table in my script, but that breaks as soon as I start multiple of the same jobs. NB: when I hover the mouse over the "Allocate node : Start" message, I do get a popup with "ID: 71" or so. All I need is that ID number within my "node {}" block .. someone please,,,
            Hide
            monger39 David Riemens added a comment -

            Devin Nusbaum : would you have an idea ? Just needed to update my pipeliine scripts, and  again the ID's changed...

            Show
            monger39 David Riemens added a comment - Devin Nusbaum : would you have an idea ? Just needed to update my pipeliine scripts, and  again the ID's changed...
            Hide
            dnusbaum Devin Nusbaum added a comment -

            David Riemens The fix to this ticket created a new page that lists all workspaces used by the build which is always accessible via a URL like <JENKINS_HOST>/jobs/<JOB_NAME>/<BUILD_NUMBER>/ws, which might be good enough for your purposes.

            If you really need to construct a link to the current workspace inside of of a Pipeline, my recommendation would be to create a new step that looks through enclosing blocks for WorkspaceAction and uses that to return or print a link to the logs. Either way, it would be better to create a new RFE or discuss on the mailing list rather than commenting on this ticket.

            Show
            dnusbaum Devin Nusbaum added a comment - David Riemens The fix to this ticket created a new page that lists all workspaces used by the build which is always accessible via a URL like <JENKINS_HOST>/jobs/<JOB_NAME>/<BUILD_NUMBER>/ws , which might be good enough for your purposes. If you really need to construct a link to the current workspace inside of of a Pipeline, my recommendation would be to create a new step that looks through enclosing blocks for WorkspaceAction and uses that to return or print a link to the logs. Either way, it would be better to create a new RFE or discuss on the mailing list rather than commenting on this ticket.

              People

              • Assignee:
                jglick Jesse Glick
                Reporter:
                jglick Jesse Glick
              • Votes:
                108 Vote for this issue
                Watchers:
                121 Start watching this issue

                Dates

                • Created:
                  Updated: