Jenkins Declarative Pipeline

1 Year Subscription

Jenkins Declarative Pipeline

Jenkins provides you with two ways of developing your pipeline code: Scripted and Declarative. Scripted pipelines, also known as “traditional” pipelines, are based on Groovy as their Domain-specific language. On the other hand, Declarative pipelines provide a simplified and more friendly syntax with specific statements for defining them, without needing to learn Groovy.

In this blog post we will cover all the directives available to develop your Declarative pipeline script, which will provide a clear picture on its functionality.

A valid Declarative pipeline must be defined with the “pipeline” sentence and include the next required sections:

Also, these are the available directives:

  • environment (Defined at stage or pipeline level)
  • input (Defined at stage level)
  • options (Defined at stage or pipeline level)
  • parallel
  • parameters
  • post
  • script
  • tools
  • triggers
  • when

We will now describe each of the listed directives/sections, starting with…


Continue reading on source link

Leave a Comment

Your email address will not be published. Required fields are marked *

85 + = 90