The following plugin provides functionality available through Pipeline-compatible steps. Read more about how to integrate steps into your Pipeline in the Steps section of the Pipeline Syntax page.

For a list of other such plugins, see the Pipeline Steps Reference page.

Pipeline: Build Step

build: Build a job

Trigger a new build for a given job.

Use the Pipeline Snippet Generator to generate a sample pipeline script for the build step.

  • job : String
    Name of a downstream job to build. May be another Pipeline job, but more commonly a freestyle or other project. Use a simple name if the job is in the same folder as this upstream Pipeline job; otherwise can use relative paths like ../sister-folder/downstream or absolute paths like /top-level-folder/nested-folder/downstream.
  • parameters (optional)
    A list of parameters to pass to the downstream job. When passing secrets to downstream jobs, prefer credentials parameters over password parameters. See the documentation for details.
      Array / List of Nested Choice of Objects
    • agentParameter
      • name : String
      • value : String
    • base64File
      • name : String
      • base64 : String (optional)
      • file (optional)
          Nested Choice of Objects
    • booleanParam
      • name : String
      • value : boolean
    • buildMasterRelease
      • name : String
      • applicationId : String
      • releaseNumber : String
      • showApplicationId : boolean
      • description : String
    • checkboxParameter
      • name : String
      • value : String
    • $class: 'ClearCaseUcmBaselineParameterValue'
      • name : String
      • baseline : String
      • forceRmview : boolean
    • credentials
      • name : String
      • value : String
      • description : String
    • $class: 'CvsTagsParamValue'
      • name : String
      • tagName : String
    • $class: 'DateParameterValue'
      • name : String
      • value : String
      • description : String
    • $class: 'DeployMetaDataParameterValue'
      • name : String
      • environmentKey : String
      • buildVersion : String
      • applicationName : String
    • file
      • name : String
      • file
          Nested Choice of Objects
    • $class: 'FileSystemListParameterValue'
      • name : String
      • value : String
    • $class: 'GeneratorKeyValueParameterValue'
      • name : String
      • value : String
    • gitParameter
      • name : String
      • value : String
    • imageTag
      • name : String
      • imageName : String
      • imageTag : String
    • $class: 'InheritableStringParameterValue'
      • name : String
      • value : String
    • $class: 'JavaParameterValue'
      • name : String
      • description : String
      • selectedJDK : String
    • $class: 'JiraIssueParameterValue'
      • name : String
      • value : String
    • $class: 'JiraVersionParameterValue'
      • name : String
      • version : String
    • $class: 'LabelParameterValue'
      • name : String
      • label : String
      • allNodesMatchingLabel : boolean
      • nodeEligibility
          Nested Choice of Objects
        • $class: 'AllNodeEligibility'
          • $class: 'IgnoreOfflineNodeEligibility'
            • $class: 'IgnoreTempOfflineNodeEligibility'
          • listGitBranches
            • name : String
            • value : String
          • $class: 'ListSubversionTagsParameterValue'
            • name : String
            • tagsDir : String
            • tag : String
          • $class: 'MatrixCombinationsParameterValue'
            • name : String
            • description : String
            • combinations : Array / List of String
            • mavenMetadataVersions
              • name : String
              • description : String
              • groupId : String
              • artifactId : String
              • version : String
              • packaging : String
              • classifier : String
              • artifactUrl : String
            • multiselect
              • name : String
              • selectedValues
                • Type: java.util.Map<java.lang.String, java.lang.String>
            • $class: 'NodeParameterValue'
              • name : String
              • labels : Array / List of String
                • nodeEligibility
                    Nested Choice of Objects
                  • $class: 'AllNodeEligibility'
                    • $class: 'IgnoreOfflineNodeEligibility'
                      • $class: 'IgnoreTempOfflineNodeEligibility'
                    • $class: 'PackageChoiceParameterValue'
                      • name : String
                      • value : String
                    • separator
                      • name : String
                      • separatorStyle : String
                      • sectionHeader : String
                      • sectionHeaderStyle : String
                    • $class: 'PatchParameterValue'
                      • name : String
                      • file
                          Nested Choice of Objects
                    • $class: 'PromotedBuildParameterValue'
                      • name : String
                      • runId : String
                      • description : String
                    • $class: 'RandomStringParameterValue'
                      • name : String
                      • value : String
                    • RESTList
                      • name : String
                      • value : String
                    • $class: 'ReviewboardParameterValue'
                      • name : String
                      • value : String
                    • run
                      • name : String
                      • runId : String
                      • description : String
                    • $class: 'SauceParameterValue'
                      • name : String
                      • selectedBrowsers : String
                    • stashedFile
                      • name : String
                      • file
                          Nested Choice of Objects
                    • string
                      • name : String
                      • value : String
                    • text
                      • name : String
                      • value : String
                    • $class: 'VBoxParameterValue'
                      • name : String
                      • nodes : Array / List of String
                        • nodeDelimiter : String
                      • email
                        • name : String
                        • value : String
                      • validatingString
                        • name : String
                        • value : String
                      • validatingYamlParameter
                        • name : String
                        • value : String
                        • failedValidationMessage : String (optional)
                      • hidden
                        • name : String
                        • value : String
                      • $class: 'WReadonlyStringParameterValue'
                        • name : String
                        • value : String
                      • $class: 'WReadonlyTextParameterValue'
                        • name : String
                        • value : String
                      • extendedChoice
                        • name : String
                        • value : String
                      • $class: 'com.michelin.cio.hudson.plugins.passwordparam.PasswordParameterValue'
                        • name : String
                        • value : String
                        • description : String
                      • $class: 'com.moded.extendedchoiceparameter.ExtendedChoiceParameterValue'
                        • name : String
                        • value : String
                      • password
                        • name : String
                        • value
                          • Type: class hudson.util.Secret
                        • description : String
                    • propagate : boolean (optional)

                      If enabled (default state), then the result of this step is that of the downstream build (e.g., success, unstable, failure, not built, or aborted). If disabled, then this step succeeds even if the downstream build is unstable, failed, etc.; use the result property of the return value as needed.

                    • quietPeriod : int (optional)
                      Optional alternate quiet period (in seconds) before building. If unset, defaults to the quiet period defined by the downstream project (or finally to the system-wide default quiet period).
                    • wait : boolean (optional)
                      If true, the pipeline will wait for the result of the build step before jumping to the next step. Defaults to true.
                    • waitForStart : boolean (optional)
                      If true, the pipeline will wait for the downstream build to start before jumping to the next step. Defaults to false. Overrides the value of wait.

                    waitForBuild: Wait for build to complete

                    Wait on a build to complete.

                    Use the Pipeline Snippet Generator to generate a sample pipeline script for the waitforBuild step.

                    • runId : String

                      The externalizableId of the build to wait on.

                    • propagate : boolean (optional)

                      If enabled, then the result of this step is that of the downstream build being waited on (e.g., success, unstable, failure, not built, or aborted). If disabled (default state), then this step succeeds even if the downstream build is unstable, failed, etc.; use the result property of the return value as needed.


                    Was this page helpful?

                    Please submit your feedback about this page through this quick form.

                    Alternatively, if you don't wish to complete the quick form, you can simply indicate if you found this page helpful?

                        


                    See existing feedback here.