What is "Pipeline as code" concept in jenkins?

0 votes
I am a beginner in Jenkins and recently came across this term "Pipeline as Code". What does this mean?
Jun 4 in Jenkins by Sam
• 290 points
22 views

1 answer to this question.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes

Jenkins "Pipeline as code"  allows you to define and automate pipelined job processes with code. Code that can be stored and versioned in a repository which allows you to track changes over time and used by jenkins to run build jobs.

To use Pipeline as code, projects must contain a file named Jenkinsfile in the repository root, which contains a "Pipeline script" that specifies the steps to execute the job.

A Jenkinsfile can be written using two types of syntax - Declarative and Scripted.

Scripted pipeline is built upon groovy and is more suitable for jobs that have a considerable amount of complexity whereas Declarative Pipeline was created to offer a simpler and more opinionated syntax for authoring Jenkins Pipeline.

You could have a look at these references for more info on the concepts of pipeline as code and also syntaxes of writing a scripted or declarative pipeline:

https://jenkins.io/doc/book/pipeline-as-code/

https://jenkins.io/doc/book/pipeline/getting-started/

https://jenkins.io/doc/book/pipeline/syntax/

For a beginner's guide on creation of pipeline tutorial you could refer to this blog:

https://www.edureka.co/blog/jenkins-pipeline-tutorial-continuous-delivery

answered Jun 4 by Sirajul
• 980 points

Related Questions In Jenkins

0 votes
1 answer
0 votes
1 answer

How to auto build a job in jenkins if there is any change in code on Github repository?

Yes this is possible. Follow these steps. 1. ...READ MORE

answered 6 days ago in Jenkins by Arvind
• 500 points
18 views
+1 vote
2 answers

What possible return values are there in Jenkins plugin “Sonarqube scanner”

Use Webhooks in SonarQube Administration setup to ...READ MORE

answered Aug 3, 2018 in Jenkins by Nilesh
• 6,900 points
1,249 views
0 votes
1 answer

unable to compile java code in Jenkins

If the code is compiling and running ...READ MORE

answered Apr 25, 2018 in Jenkins by DareDev
• 6,710 points
118 views
+13 votes
2 answers
0 votes
1 answer
+1 vote
1 answer

Is there a way to restrict permissions to a user per individual job in jenkins?

Yes, you can configure user permissions per ...READ MORE

answered May 28 in Jenkins by Sirajul
• 980 points

edited May 28 by Sirajul 40 views
0 votes
1 answer

© 2018 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved.
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of MongoDB, Inc.