SD DevOps Meet-up - Jenkins 2.0 and Pipeline-as-Code
17 de Mar de 2016•0 gostou
9 gostaram
Seja o primeiro a gostar disto
mostrar mais
•3,096 visualizações
visualizações
Vistos totais
0
No Slideshare
0
De incorporações
0
Número de incorporações
0
Baixar para ler offline
Denunciar
Engenharia
This is a presentation given at the March 16th San Diego DevOps Meet-up covering some of the upcoming activities around Jenkin 2.0 and the Pipeline plugins which provide for Pipeline-as-Code and enable Jenkins with 1st class pipelines and stages.
About Jenkins
Jenkins 2.0 is an automation engine with an
unparalleled plugin ecosystem to support all of your
favorite tools in your delivery pipelines, whether your
goal is continuous integration, automated testing, or
continuous delivery.
Jenkins weaknesses. Compatibility costs
9
• More than 5 years of backward compatibility
• Hudson 2 plugins still work on Jenkins!
• BUT:
• Architecture design issues, complex APIs
• Outdated libs
• Outdated UI
• Plugin integration issues
...Fixes are on the way
Pipelines in Jenkins 1.x
●Create jobs
●Trigger “downstream” jobs for next stage
●Easy!
Pipeline as Code
● Introduce “pipeline” as a new type in Jenkins
● Codify an implicit series of stages into an explicit
.Jenkinsfile in your source repository
● Resumability/durability of the pipeline state
● Extend the DSL with your own steps
github.com/jenkinsci/pipeline-examples
Pipeline DSL
node('docker') {
checkout scm
/* Grab the abbreviated SHA1 of our pipeline’s commit.
*/
sh 'git rev-parse HEAD > GIT_COMMIT'
def shortCommit = readFile('GIT_COMMIT').take(6)
stage 'Build'
def image = docker.build("jenkinsciinfra/bind:build-${shortCommit}")
stage 'Deploy'
image.push()
}
New Community Site: jenkins.io (Beta)
● Modern platform and UI
● Easier to use
● 1-2-3-4 Quickstart
● Centralized Documentation
● Solution-oriented Use
Cases
● Events listings
● Launching March 22nd
Here are some really cool features in Jenkins Workflow.
SAs talk here about coolness of Workflow.
As we said, CD involves creating Pipelines for application code.
This means that for every code “check-in” by every developer, the new code needs to go through the Pipeline that will take it from Dev to Prod.
So, the CD Platform needs to manage the execution of many of these Pipelines.
And the pipelines can be complex. They may have decision points or branches. They may need to be paused or restarted.
Modeling the real-world process of application delivery requires that these pipelines be robust, flexible and powerful.
Here’s a real-world example of a complex CD Pipeline used by a Jenkins Workflow user.
The CloudBees Jenkins Platform also provides a dashboard that shows the current state of the pipeline activity, such as this example, which is critical to providing a full understanding of how things are performing.