SlideShare a Scribd company logo
Orchestrating the Continuous Delivery 
Process in Jenkins with Workflow 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
1
Today’s Presenters 
Cyrille Le Clerc 
Director, Product Management 
cleclerc@cloudbees.com 
@cyrilleleclerc 
Steve Harris 
SVP, Products 
sharris@cloudbees.com 
@stevengharris 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
2
Using WebEx 
Questions? 
Submit via the Q&A window 
at any time during the 
presentation. 
We will cover Q&A at the 
end of the presentation. 
Session is being recorded. 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
3
Agenda 
• Con=nuous 
Delivery 
• Jenkins 
& 
Con=nuous 
Delivery 
• Workflow 
in 
Jenkins 
Today 
• The 
New 
Jenkins 
Workflow 
Engine 
• Jenkins 
Workflow 
Syntax 
Card 
• Possible 
Futures 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
4
Continuous Delivery 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
5
Continuous Delivery 
• “Reliable 
So+ware 
Releases 
through 
Build, 
Test, 
and 
Deployment 
Automa=on” 
• DONE 
= 
Shippable 
into 
Produc=on 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
6
Continuous Integration Steps 
Con$nuous 
Integra$on 
Source Code 
Quality Analysis 
Compile & 
Unit Tests 
Binaries 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
7
Continuous Delivery Steps 
Con$nuous 
Delivery 
DEV 
DEV 
QA 
OPS 
Source Code 
Quality Analysis 
Compile & 
Unit Tests 
Binaries 
Perfs Environment 
Func Test Environment 
UAT Environment 
Production Environment 
GO LIVE! 
Release! 
Staging Environment 
8
Continuous Delivery Pipeline 
Continuous Delivery Pipeline 
Compile & 
Unit Tests 
Perfs Tests 
Selenium Tests Deploy UAT 
Sonar Analysis 
Deploy Staging Deploy Production 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
9
Jenkins: Hub of Continuous Delivery 
• Connect 
the 
dots 
• It 
is 
the 
process 
Source Code 
Perfs Environment 
Func Test Environment 
UAT Environment 
Binaries 
Quality Analysis 
Compile & 
Unit Tests 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
10
CI/CD with Jenkins and Vagrant and Puppet 
puppet 
deployment 
module 
java 
code 
Dev Environment 
vagrant provision 
puppet apply 
war file + puppet manifests & 
modules 
petclinic.war 
Puppet Agent 
App. Server 
QA Environment 
petclinic.war 
Puppet Agent 
App. Server 
Prod Environment 
petclinic.war 
Puppet Agent 
App. Server 
war file + puppet manifests & modules 
Puppet 
Master 
Puppet 
Master 
OPS 
war file + puppet manifests & modules 
Jenkins 
builds 
war 
file 
and 
Puppet 
modules 
and 
deploys 
via 
Vagrant
CI/CD with Jenkins and Vagrant and Puppet 
puppet 
deployment 
module 
java 
code 
Dev Environment 
notification 
vagrant provision 
puppet apply 
war file + puppet manifests & 
modules 
petclinic.war 
Puppet Agent 
App. Server 
QA Environment 
petclinic.war 
Puppet Agent 
App. Server 
Prod Environment 
petclinic.war 
Puppet Agent 
App. Server 
notification 
war file + puppet manifests & modules 
Puppet 
Master 
Puppet 
Master 
OPS 
war file + puppet manifests & modules 
Jenkins 
builds 
war 
file 
and 
Puppet 
modules 
and 
deploys 
via 
Vagrant
Jenkins – Puppet Integration
CD Pipeline è Workflow 
Continuous Delivery Pipeline 
Compile & 
Unit Tests 
Perfs Tests 
Selenium Tests Deploy UAT 
Sonar Analysis 
Deploy Staging Deploy Production 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
14
What We Need 
• Complex 
pipelines 
involving 
mul=ple 
stages 
• Non-­‐sequen$al 
logic 
such 
as 
loops, 
forks 
… 
• Long-­‐running 
builds 
must 
survive 
outages 
• Interac$ons 
with 
humans 
including 
pauses, 
input 
• Restartable 
builds 
in 
case 
of 
transient 
errors 
• Reusable 
defini$ons 
to 
avoid 
duplica=on 
• Comprehensible 
scripts 
with 
one 
clear 
defini=on 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
15
Most Existing Workflow In Jenkins Today 
• Job 
Chaining 
• Build 
Flow 
Plugin 
• Build 
Pipeline 
Plugin 
• Build 
Delivery 
Pipeline 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
16
Most Existing Workflow In Jenkins Today 
• Many 
atomic 
jobs 
• Hard 
to 
share 
variables/state 
between 
jobs 
• Limited 
logic 
• Mix 
build 
triggers, 
parameterized 
build 
… 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
17
Jenkins Workflow Engine 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
18
Simplifying Our Sample Workflow 
Compile & 
Unit Tests 
Perfs Tests 
Selenium Tests Deploy UAT 
Sonar Analysis 
Deploy Staging Deploy Production 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
19
Simplifying Our Sample Workflow 
Compile & 
Unit Tests 
Perfs Tests 
Selenium Tests Deploy UAT 
Sonar Analysis 
Deploy Staging Deploy Production 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
20
What We Need 
• Complex 
pipelines 
involving 
mul=ple 
stages 
• Non-­‐sequen$al 
logic 
such 
as 
loops, 
forks 
… 
• Long-­‐running 
builds 
must 
survive 
outages 
• Interac$ons 
with 
humans 
including 
pauses, 
input 
• Restartable 
builds 
in 
case 
of 
transient 
errors 
• Reusable 
defini$ons 
to 
avoid 
duplica=on 
• Comprehensible 
scripts 
with 
one 
clear 
defini=on 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
21
New Workflow Syntax 
22
Production Release Available NOW! 
• Jenkins 
OSS 
– Workflow 
1.0 
released 
December 
3 
• Beta 
out 
since 
May, 
with 
great, 
engaged 
feedback 
• Install 
Workflow: 
Aggregator 
in 
LTS 
1.580.x 
or 
a 
later 
weekly 
release 
• Jenkins 
Enterprise 
by 
CloudBees 
– Automa=cally 
available 
as 
of 
the 
14.11 
release 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
23
Demo Time! 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
24
Key Features 
• En=re 
flow 
is 
one 
concise 
Groovy 
script 
– For 
loops, 
try-­‐finally, 
fork-­‐join 
… 
• Can 
restart 
Jenkins 
while 
flow 
is 
running 
• Allocate 
slave 
nodes 
and 
workspaces 
– As 
many 
as 
you 
want, 
when 
you 
want 
• Stages 
throdle 
concurrency 
of 
builds 
• Human 
input/approval 
integrated 
into 
flow 
• Standard 
project 
concepts: 
SCM, 
ar=facts, 
plugins 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
25
Groovy DSL vs. Graphical Workflow 
• Familiar 
control 
flow 
construc=on 
• Familiar 
“tools” 
for 
building 
abstrac=ons 
Func=ons, 
classes, 
variables, 
… 
• Workflow 
in 
version 
control 
• As 
opposed 
to: 
Graphical 
workflow 
designer 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
26
Project Setup 
• One 
workflow 
is 
defined 
as 
a 
job 
• Single 
script 
for 
all 
steps 
• Build 
triggers 
& 
parameters 
like 
regular 
projects 
• Each 
workflow 
execu=on 
is 
a 
regular 
Jenkins 
build 
displayed 
in 
regular 
Jenkins 
views 
• Graphical 
visualiza=on 
of 
actual 
build 
possible 
Not 
of 
visualiza=on 
job 
defini=on 
but 
of 
build 
execu=on 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
27
Non-Sequential Logic 
timeout(time: 300, unit: 'SECONDS') { 
} 
try {} catch {} 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
28
Interaction with Humans 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
29
Restartable Build / Checkpoint 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
30
Visualization 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
31
Stages 
• Semaphore 
• Visualiza=on 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
32
Comprehensible Scripts 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
33
Workflow Syntax Card 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
34
Workflow Syntax Card 
• stage: 
Enter 
a 
new 
stage 
• node: 
Allocate 
node 
• ws: 
Allocate 
workspace 
• parallel: 
Execute 
sub-­‐workflow 
in 
parallel 
• retry: 
Retry 
the 
body 
up 
to 
N 
=mes 
• catchError: 
Catch 
error 
and 
con=nue 
• timeout: 
Execute 
the 
body 
with 
a 
=meout 
• input: 
Input 
/ 
human 
interac=on 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
35
Workflow Syntax Card 
• load: 
Evaluate 
a 
Groovy 
source 
file 
into 
the 
workflow 
script 
• step: 
General 
build 
step 
• sh: 
Shell 
script 
• bat: 
Windows 
batch 
script 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
36
Workflow Syntax Card 
• archive: 
Archive 
ar=facts 
• unarchive: 
Copy 
archived 
ar=fact 
into 
the 
workspace 
• echo: 
Print 
message 
• dir: 
Change 
directory 
• readFile: 
Read 
file 
from 
workspace 
• writeFile: 
Write 
file 
to 
workspace 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
37
Workflow Syntax Card 
• git: 
Git 
• svn: 
Subversion 
• scm: 
General 
SCM 
• tool: 
install 
a 
tool 
• build: 
Build 
a 
job 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
38
Workflow Syntax Card 
• checkpoint: 
capture 
the 
state 
of 
the 
execu=on 
so 
that 
it 
can 
be 
restarted 
later 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
39
Possible Futures 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
40
Possible Futures 
Probably OSS 
• More 
plugin 
interoperability 
• Mul=-­‐branch 
project 
(& 
SCM 
API) 
integra=on 
• More 
advanced 
SCM 
• In-­‐IDE 
edi=ng 
support 
• Concise 
syntax 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
41
Possible Futures 
Probably CloudBees Jenkins Enterprise and Operations Center 
• More 
visualiza=ons 
• Validated 
merge 
integra=on 
• Deployment, 
incl. 
blue/green 
with 
rollback 
• Freestyle 
and/or 
Build 
Flow 
import 
• Templates 
integra=on 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
42
Get The Code 
• hdps://gist.github.com/cyrille-­‐leclerc/0dc73659e6d2a92f014a 
– workflow.groovy 
• hdps://github.com/cyrille-­‐leclerc/spring-­‐petclinic/ 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
43
More Workflow Resources 
• Tutorial 
– hdps://github.com/jenkinsci/workflow-­‐ 
plugin/blob/master/TUTORIAL.md 
• Jenkins 
Enterprise 
by 
CloudBees 
Workflow-­‐related 
Func=onality 
– hdp://jenkins-­‐enterprise.cloudbees.com/ 
docs/user-­‐guide-­‐docs/workflow.html 
• More 
webinars 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
44
Cyrille Le Clerc 
Director, Product Management 
cleclerc@cloudbees.com 
@cyrilleleclerc 
Steve Harris 
SVP, Products 
sharris@cloudbees.com 
@stevengharris 
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
45
©2014 
CloudBees, 
Inc. 
All 
Rights 
Reserved 
46

More Related Content

PDF
Continuous Delivery with Jenkins Workflow
Udaypal Aarkoti
 
PDF
Pimp your Continuous Delivery Pipeline with Jenkins workflow (W-JAX 14)
CloudBees
 
PPTX
Javaone 2014 - Git & Docker with Jenkins
Andy Pemberton
 
PPTX
Automated Deployment Pipeline using Jenkins, Puppet, Mcollective and AWS
Bamdad Dashtban
 
PDF
Analyze This! CloudBees Jenkins Cluster Operations and Analytics
CloudBees
 
PDF
CI and CD Across the Enterprise with Jenkins (devops.com Nov 2014)
CloudBees
 
PDF
JavaCro'14 - Continuous delivery of Java EE applications with Jenkins and Doc...
HUJAK - Hrvatska udruga Java korisnika / Croatian Java User Association
 
PDF
From Continuous Integration to Continuous Delivery with Jenkins - javaland.de...
CloudBees
 
Continuous Delivery with Jenkins Workflow
Udaypal Aarkoti
 
Pimp your Continuous Delivery Pipeline with Jenkins workflow (W-JAX 14)
CloudBees
 
Javaone 2014 - Git & Docker with Jenkins
Andy Pemberton
 
Automated Deployment Pipeline using Jenkins, Puppet, Mcollective and AWS
Bamdad Dashtban
 
Analyze This! CloudBees Jenkins Cluster Operations and Analytics
CloudBees
 
CI and CD Across the Enterprise with Jenkins (devops.com Nov 2014)
CloudBees
 
JavaCro'14 - Continuous delivery of Java EE applications with Jenkins and Doc...
HUJAK - Hrvatska udruga Java korisnika / Croatian Java User Association
 
From Continuous Integration to Continuous Delivery with Jenkins - javaland.de...
CloudBees
 

What's hot (20)

PDF
Rundeck + Nexus (from Nexus Live on June 5, 2014)
dev2ops
 
PDF
Continuous Delivery Pipeline with Docker and Jenkins
Camilo Ribeiro
 
PPTX
SD DevOps Meet-up - Jenkins 2.0 and Pipeline-as-Code
Brian Dawson
 
PDF
Docker Enables DevOps
Boyd Hemphill
 
PPTX
Delivery Pipeline as Code: using Jenkins 2.0 Pipeline
Slawa Giterman
 
PDF
Building a Service Delivery Platform - JCICPH 2014
Andreas Rehn
 
PDF
Testing with Docker
toffermann
 
ODP
Jenkinsconf Presentation - Advance jenkins management with multiple projects.
Ohad Basan
 
PPTX
Anatomy of a Build Pipeline
Samuel Brown
 
PDF
At Your Service: Using Jenkins in Operations
Mandi Walls
 
PPTX
Continuous Development with Jenkins - Stephen Connolly at PuppetCamp Dublin '12
Puppet
 
PPTX
2016 Docker Palo Alto - CD with ECS and Jenkins
Tracy Kennedy
 
PPTX
CI/CD Pipeline to Deploy and Maintain an OpenStack IaaS Cloud
Simon McCartney
 
PPTX
Continuous Delivery with Jenkins and Wildfly (2014)
Tracy Kennedy
 
PDF
Using Docker for Testing
Carlos Sanchez
 
PDF
Brujug Jenkins pipeline scalability
Damien Coraboeuf
 
PDF
An Open-Source Chef Cookbook CI/CD Implementation Using Jenkins Pipelines
Steffen Gebert
 
PPTX
Jenkins days workshop pipelines - Eric Long
ericlongtx
 
PDF
DevOps@Morpho for ParisDevOps - 2nd of December 2014
Jean-Charles JOREL
 
PDF
Jenkins vs. AWS CodePipeline (AWS User Group Berlin)
Steffen Gebert
 
Rundeck + Nexus (from Nexus Live on June 5, 2014)
dev2ops
 
Continuous Delivery Pipeline with Docker and Jenkins
Camilo Ribeiro
 
SD DevOps Meet-up - Jenkins 2.0 and Pipeline-as-Code
Brian Dawson
 
Docker Enables DevOps
Boyd Hemphill
 
Delivery Pipeline as Code: using Jenkins 2.0 Pipeline
Slawa Giterman
 
Building a Service Delivery Platform - JCICPH 2014
Andreas Rehn
 
Testing with Docker
toffermann
 
Jenkinsconf Presentation - Advance jenkins management with multiple projects.
Ohad Basan
 
Anatomy of a Build Pipeline
Samuel Brown
 
At Your Service: Using Jenkins in Operations
Mandi Walls
 
Continuous Development with Jenkins - Stephen Connolly at PuppetCamp Dublin '12
Puppet
 
2016 Docker Palo Alto - CD with ECS and Jenkins
Tracy Kennedy
 
CI/CD Pipeline to Deploy and Maintain an OpenStack IaaS Cloud
Simon McCartney
 
Continuous Delivery with Jenkins and Wildfly (2014)
Tracy Kennedy
 
Using Docker for Testing
Carlos Sanchez
 
Brujug Jenkins pipeline scalability
Damien Coraboeuf
 
An Open-Source Chef Cookbook CI/CD Implementation Using Jenkins Pipelines
Steffen Gebert
 
Jenkins days workshop pipelines - Eric Long
ericlongtx
 
DevOps@Morpho for ParisDevOps - 2nd of December 2014
Jean-Charles JOREL
 
Jenkins vs. AWS CodePipeline (AWS User Group Berlin)
Steffen Gebert
 
Ad

Viewers also liked (11)

ODP
PyVo & BRUG - automating github workflow with Jenkins CI
Vaclav Tunka
 
PDF
Tp install anything
Alessandro Franceschi
 
PDF
Puppet & Jenkins
Matthew Barr
 
PDF
Puppet and AWS is Easy...?
Puppet
 
PDF
Puppet control-repo 
to the next level
Alessandro Franceschi
 
PDF
PuppetConf 2016: Deconfiguration Management: Making Puppet Clean Up Its Own M...
Puppet
 
PPTX
Drupal Continuous Integration Workflow
Andrii Podanenko
 
PDF
20150523 chatwork continuous delivery
Yoshinori Fujiwara
 
PPTX
Transforming Organizations with CI/CD
Cprime
 
PDF
DDDハンズオン
Soudai Sone
 
PDF
Ansibleで始めるインフラ構築自動化
dcubeio
 
PyVo & BRUG - automating github workflow with Jenkins CI
Vaclav Tunka
 
Tp install anything
Alessandro Franceschi
 
Puppet & Jenkins
Matthew Barr
 
Puppet and AWS is Easy...?
Puppet
 
Puppet control-repo 
to the next level
Alessandro Franceschi
 
PuppetConf 2016: Deconfiguration Management: Making Puppet Clean Up Its Own M...
Puppet
 
Drupal Continuous Integration Workflow
Andrii Podanenko
 
20150523 chatwork continuous delivery
Yoshinori Fujiwara
 
Transforming Organizations with CI/CD
Cprime
 
DDDハンズオン
Soudai Sone
 
Ansibleで始めるインフラ構築自動化
dcubeio
 
Ad

Similar to Jenkins Workflow Webinar - Dec 10, 2014 (20)

PDF
Atlanta Jenkins Area Meetup October 22nd 2015
Kurt Madel
 
PDF
Journée DevOps : De l'intégration continue au déploiement continu avec Jenkins
Publicis Sapient Engineering
 
PDF
413450-rc218-cdw-jenkins-workflow
Andy Pemberton
 
PPTX
Workflow, container, and beyond
Kohsuke Kawaguchi
 
PDF
Webinar: "Continuous Delivery with Jenkins"
Emerasoft, solutions to collaborate
 
PDF
Continuous Integration
Udaypal Aarkoti
 
PPTX
7 Habits of Highly Effective Jenkins Users
Jules Pierre-Louis
 
PDF
Jenkins Days - Workshop - Let's Build a Pipeline - Los Angeles
Andy Pemberton
 
PDF
Continuous Delivery with Jenkins Enterprise and IBM UrbanCode Deploy
IBM UrbanCode Products
 
PDF
The Butler is still young – applying modern Jenkins features to the Embedded ...
Oleg Nenashev
 
PPTX
Jenkins2 - Coding Continuous Delivery Pipelines
Brent Laster
 
PDF
JavaOne 2016 - Pipeline as code
Bert Jan Schrijver
 
PDF
jenkins.pdf
shahidafrith
 
PDF
Jenkins_1679702972.pdf
MahmoudAlnmr1
 
PDF
Who *is* Jenkins?
Andrew Bayer
 
PDF
Pipeline: Continuous Delivery as Code in Jenkins 2.0
Jules Pierre-Louis
 
PDF
7 Habits of Highly Effective Jenkins Users
Jules Pierre-Louis
 
PPTX
DevOps-CI_CD_JAVA_JAVA______Jenkins.pptx
ajaysahu931430
 
PDF
JUC Europe 2015: Bringing CD at Cloud-Scale with Jenkins, Docker and "Tiger"
CloudBees
 
PPTX
Louisville Software Engineering Meet Up: Continuous Integration Using Jenkins
James Strong
 
Atlanta Jenkins Area Meetup October 22nd 2015
Kurt Madel
 
Journée DevOps : De l'intégration continue au déploiement continu avec Jenkins
Publicis Sapient Engineering
 
413450-rc218-cdw-jenkins-workflow
Andy Pemberton
 
Workflow, container, and beyond
Kohsuke Kawaguchi
 
Webinar: "Continuous Delivery with Jenkins"
Emerasoft, solutions to collaborate
 
Continuous Integration
Udaypal Aarkoti
 
7 Habits of Highly Effective Jenkins Users
Jules Pierre-Louis
 
Jenkins Days - Workshop - Let's Build a Pipeline - Los Angeles
Andy Pemberton
 
Continuous Delivery with Jenkins Enterprise and IBM UrbanCode Deploy
IBM UrbanCode Products
 
The Butler is still young – applying modern Jenkins features to the Embedded ...
Oleg Nenashev
 
Jenkins2 - Coding Continuous Delivery Pipelines
Brent Laster
 
JavaOne 2016 - Pipeline as code
Bert Jan Schrijver
 
jenkins.pdf
shahidafrith
 
Jenkins_1679702972.pdf
MahmoudAlnmr1
 
Who *is* Jenkins?
Andrew Bayer
 
Pipeline: Continuous Delivery as Code in Jenkins 2.0
Jules Pierre-Louis
 
7 Habits of Highly Effective Jenkins Users
Jules Pierre-Louis
 
DevOps-CI_CD_JAVA_JAVA______Jenkins.pptx
ajaysahu931430
 
JUC Europe 2015: Bringing CD at Cloud-Scale with Jenkins, Docker and "Tiger"
CloudBees
 
Louisville Software Engineering Meet Up: Continuous Integration Using Jenkins
James Strong
 

More from CloudBees (20)

PDF
JUC Europe 2015: Scaling Your Jenkins Master with Docker
CloudBees
 
PDF
JUC Europe 2015: Plugin Development with Gradle and Groovy
CloudBees
 
PDF
JUC Europe 2015: Multi-Node Environment as a Jenkins Slave (Compound-Slave)
CloudBees
 
PDF
JUC Europe 2015: The Famous Cows of Cambridge: A Non-Standard Use Case for Je...
CloudBees
 
PDF
JUC Europe 2015: Jenkins Made Easy
CloudBees
 
PDF
JUC Europe 2015: Scaling of Jenkins Pipeline Creation and Maintenance
CloudBees
 
PDF
JUC Europe 2015: From Virtual Machines to Containers: Achieving Continuous In...
CloudBees
 
PDF
JUC Europe 2015: Hey! What Did We Just Release?
CloudBees
 
PDF
JUC Europe 2015: Orchestrating Your Pipelines with Jenkins, Python and the Je...
CloudBees
 
PDF
JUC Europe 2015: Jenkins Pipeline for Continuous Delivery of Big Data Projects
CloudBees
 
PDF
JUC Europe 2015: Jenkins-Based Continuous Integration for Heterogeneous Hardw...
CloudBees
 
PDF
JUC Europe 2015: Optimizing Your CI: Lessons Learned from a Successful Jenkin...
CloudBees
 
PDF
JUC Europe 2015: Enabling Continuous Delivery for Major Retailers
CloudBees
 
PDF
JUC Europe 2015: Making Strides towards Enterprise-Scale DevOps...with Jenkin...
CloudBees
 
PDF
JUC Europe 2015: Evolving the Jenkins UI
CloudBees
 
PDF
JUC Europe 2015: Using Infrastructure Nodes Wisely With Jenkins and Apache Mesos
CloudBees
 
PDF
JUC Europe 2015: How to Optimize Automated Testing with Everyone's Favorite B...
CloudBees
 
PDF
JUC 2015 - Keynote Address and Opening Remarks by Kohsuke Kawaguchi, Founder,...
CloudBees
 
PDF
JUC Europe 2015: Continuous Integration and Distribution in the Cloud with DE...
CloudBees
 
PDF
JUC Europe 2015: Configuration as Code: The Job DSL Plugin
CloudBees
 
JUC Europe 2015: Scaling Your Jenkins Master with Docker
CloudBees
 
JUC Europe 2015: Plugin Development with Gradle and Groovy
CloudBees
 
JUC Europe 2015: Multi-Node Environment as a Jenkins Slave (Compound-Slave)
CloudBees
 
JUC Europe 2015: The Famous Cows of Cambridge: A Non-Standard Use Case for Je...
CloudBees
 
JUC Europe 2015: Jenkins Made Easy
CloudBees
 
JUC Europe 2015: Scaling of Jenkins Pipeline Creation and Maintenance
CloudBees
 
JUC Europe 2015: From Virtual Machines to Containers: Achieving Continuous In...
CloudBees
 
JUC Europe 2015: Hey! What Did We Just Release?
CloudBees
 
JUC Europe 2015: Orchestrating Your Pipelines with Jenkins, Python and the Je...
CloudBees
 
JUC Europe 2015: Jenkins Pipeline for Continuous Delivery of Big Data Projects
CloudBees
 
JUC Europe 2015: Jenkins-Based Continuous Integration for Heterogeneous Hardw...
CloudBees
 
JUC Europe 2015: Optimizing Your CI: Lessons Learned from a Successful Jenkin...
CloudBees
 
JUC Europe 2015: Enabling Continuous Delivery for Major Retailers
CloudBees
 
JUC Europe 2015: Making Strides towards Enterprise-Scale DevOps...with Jenkin...
CloudBees
 
JUC Europe 2015: Evolving the Jenkins UI
CloudBees
 
JUC Europe 2015: Using Infrastructure Nodes Wisely With Jenkins and Apache Mesos
CloudBees
 
JUC Europe 2015: How to Optimize Automated Testing with Everyone's Favorite B...
CloudBees
 
JUC 2015 - Keynote Address and Opening Remarks by Kohsuke Kawaguchi, Founder,...
CloudBees
 
JUC Europe 2015: Continuous Integration and Distribution in the Cloud with DE...
CloudBees
 
JUC Europe 2015: Configuration as Code: The Job DSL Plugin
CloudBees
 

Recently uploaded (20)

PDF
GDG Cloud Munich - Intro - Luiz Carneiro - #BuildWithAI - July - Abdel.pdf
Luiz Carneiro
 
PPTX
Introduction to Flutter by Ayush Desai.pptx
ayushdesai204
 
PDF
Presentation about Hardware and Software in Computer
snehamodhawadiya
 
PPTX
OA presentation.pptx OA presentation.pptx
pateldhruv002338
 
PDF
Unlocking the Future- AI Agents Meet Oracle Database 23ai - AIOUG Yatra 2025.pdf
Sandesh Rao
 
PDF
Oracle AI Vector Search- Getting Started and what's new in 2025- AIOUG Yatra ...
Sandesh Rao
 
PDF
Accelerating Oracle Database 23ai Troubleshooting with Oracle AHF Fleet Insig...
Sandesh Rao
 
PDF
Orbitly Pitch Deck|A Mission-Driven Platform for Side Project Collaboration (...
zz41354899
 
PDF
MASTERDECK GRAPHSUMMIT SYDNEY (Public).pdf
Neo4j
 
PDF
Peak of Data & AI Encore - Real-Time Insights & Scalable Editing with ArcGIS
Safe Software
 
PDF
How ETL Control Logic Keeps Your Pipelines Safe and Reliable.pdf
Stryv Solutions Pvt. Ltd.
 
PDF
CIFDAQ's Market Wrap : Bears Back in Control?
CIFDAQ
 
PPTX
The Future of AI & Machine Learning.pptx
pritsen4700
 
PPTX
AI in Daily Life: How Artificial Intelligence Helps Us Every Day
vanshrpatil7
 
PPTX
Agile Chennai 18-19 July 2025 Ideathon | AI Powered Microfinance Literacy Gui...
AgileNetwork
 
PDF
Automating ArcGIS Content Discovery with FME: A Real World Use Case
Safe Software
 
PPTX
cloud computing vai.pptx for the project
vaibhavdobariyal79
 
PPTX
Dev Dives: Automate, test, and deploy in one place—with Unified Developer Exp...
AndreeaTom
 
PDF
AI Unleashed - Shaping the Future -Starting Today - AIOUG Yatra 2025 - For Co...
Sandesh Rao
 
PDF
Doc9.....................................
SofiaCollazos
 
GDG Cloud Munich - Intro - Luiz Carneiro - #BuildWithAI - July - Abdel.pdf
Luiz Carneiro
 
Introduction to Flutter by Ayush Desai.pptx
ayushdesai204
 
Presentation about Hardware and Software in Computer
snehamodhawadiya
 
OA presentation.pptx OA presentation.pptx
pateldhruv002338
 
Unlocking the Future- AI Agents Meet Oracle Database 23ai - AIOUG Yatra 2025.pdf
Sandesh Rao
 
Oracle AI Vector Search- Getting Started and what's new in 2025- AIOUG Yatra ...
Sandesh Rao
 
Accelerating Oracle Database 23ai Troubleshooting with Oracle AHF Fleet Insig...
Sandesh Rao
 
Orbitly Pitch Deck|A Mission-Driven Platform for Side Project Collaboration (...
zz41354899
 
MASTERDECK GRAPHSUMMIT SYDNEY (Public).pdf
Neo4j
 
Peak of Data & AI Encore - Real-Time Insights & Scalable Editing with ArcGIS
Safe Software
 
How ETL Control Logic Keeps Your Pipelines Safe and Reliable.pdf
Stryv Solutions Pvt. Ltd.
 
CIFDAQ's Market Wrap : Bears Back in Control?
CIFDAQ
 
The Future of AI & Machine Learning.pptx
pritsen4700
 
AI in Daily Life: How Artificial Intelligence Helps Us Every Day
vanshrpatil7
 
Agile Chennai 18-19 July 2025 Ideathon | AI Powered Microfinance Literacy Gui...
AgileNetwork
 
Automating ArcGIS Content Discovery with FME: A Real World Use Case
Safe Software
 
cloud computing vai.pptx for the project
vaibhavdobariyal79
 
Dev Dives: Automate, test, and deploy in one place—with Unified Developer Exp...
AndreeaTom
 
AI Unleashed - Shaping the Future -Starting Today - AIOUG Yatra 2025 - For Co...
Sandesh Rao
 
Doc9.....................................
SofiaCollazos
 

Jenkins Workflow Webinar - Dec 10, 2014

  • 1. Orchestrating the Continuous Delivery Process in Jenkins with Workflow ©2014 CloudBees, Inc. All Rights Reserved 1
  • 2. Today’s Presenters Cyrille Le Clerc Director, Product Management [email protected] @cyrilleleclerc Steve Harris SVP, Products [email protected] @stevengharris ©2014 CloudBees, Inc. All Rights Reserved 2
  • 3. Using WebEx Questions? Submit via the Q&A window at any time during the presentation. We will cover Q&A at the end of the presentation. Session is being recorded. ©2014 CloudBees, Inc. All Rights Reserved 3
  • 4. Agenda • Con=nuous Delivery • Jenkins & Con=nuous Delivery • Workflow in Jenkins Today • The New Jenkins Workflow Engine • Jenkins Workflow Syntax Card • Possible Futures ©2014 CloudBees, Inc. All Rights Reserved 4
  • 5. Continuous Delivery ©2014 CloudBees, Inc. All Rights Reserved 5
  • 6. Continuous Delivery • “Reliable So+ware Releases through Build, Test, and Deployment Automa=on” • DONE = Shippable into Produc=on ©2014 CloudBees, Inc. All Rights Reserved 6
  • 7. Continuous Integration Steps Con$nuous Integra$on Source Code Quality Analysis Compile & Unit Tests Binaries ©2014 CloudBees, Inc. All Rights Reserved 7
  • 8. Continuous Delivery Steps Con$nuous Delivery DEV DEV QA OPS Source Code Quality Analysis Compile & Unit Tests Binaries Perfs Environment Func Test Environment UAT Environment Production Environment GO LIVE! Release! Staging Environment 8
  • 9. Continuous Delivery Pipeline Continuous Delivery Pipeline Compile & Unit Tests Perfs Tests Selenium Tests Deploy UAT Sonar Analysis Deploy Staging Deploy Production ©2014 CloudBees, Inc. All Rights Reserved 9
  • 10. Jenkins: Hub of Continuous Delivery • Connect the dots • It is the process Source Code Perfs Environment Func Test Environment UAT Environment Binaries Quality Analysis Compile & Unit Tests ©2014 CloudBees, Inc. All Rights Reserved 10
  • 11. CI/CD with Jenkins and Vagrant and Puppet puppet deployment module java code Dev Environment vagrant provision puppet apply war file + puppet manifests & modules petclinic.war Puppet Agent App. Server QA Environment petclinic.war Puppet Agent App. Server Prod Environment petclinic.war Puppet Agent App. Server war file + puppet manifests & modules Puppet Master Puppet Master OPS war file + puppet manifests & modules Jenkins builds war file and Puppet modules and deploys via Vagrant
  • 12. CI/CD with Jenkins and Vagrant and Puppet puppet deployment module java code Dev Environment notification vagrant provision puppet apply war file + puppet manifests & modules petclinic.war Puppet Agent App. Server QA Environment petclinic.war Puppet Agent App. Server Prod Environment petclinic.war Puppet Agent App. Server notification war file + puppet manifests & modules Puppet Master Puppet Master OPS war file + puppet manifests & modules Jenkins builds war file and Puppet modules and deploys via Vagrant
  • 13. Jenkins – Puppet Integration
  • 14. CD Pipeline è Workflow Continuous Delivery Pipeline Compile & Unit Tests Perfs Tests Selenium Tests Deploy UAT Sonar Analysis Deploy Staging Deploy Production ©2014 CloudBees, Inc. All Rights Reserved 14
  • 15. What We Need • Complex pipelines involving mul=ple stages • Non-­‐sequen$al logic such as loops, forks … • Long-­‐running builds must survive outages • Interac$ons with humans including pauses, input • Restartable builds in case of transient errors • Reusable defini$ons to avoid duplica=on • Comprehensible scripts with one clear defini=on ©2014 CloudBees, Inc. All Rights Reserved 15
  • 16. Most Existing Workflow In Jenkins Today • Job Chaining • Build Flow Plugin • Build Pipeline Plugin • Build Delivery Pipeline ©2014 CloudBees, Inc. All Rights Reserved 16
  • 17. Most Existing Workflow In Jenkins Today • Many atomic jobs • Hard to share variables/state between jobs • Limited logic • Mix build triggers, parameterized build … ©2014 CloudBees, Inc. All Rights Reserved 17
  • 18. Jenkins Workflow Engine ©2014 CloudBees, Inc. All Rights Reserved 18
  • 19. Simplifying Our Sample Workflow Compile & Unit Tests Perfs Tests Selenium Tests Deploy UAT Sonar Analysis Deploy Staging Deploy Production ©2014 CloudBees, Inc. All Rights Reserved 19
  • 20. Simplifying Our Sample Workflow Compile & Unit Tests Perfs Tests Selenium Tests Deploy UAT Sonar Analysis Deploy Staging Deploy Production ©2014 CloudBees, Inc. All Rights Reserved 20
  • 21. What We Need • Complex pipelines involving mul=ple stages • Non-­‐sequen$al logic such as loops, forks … • Long-­‐running builds must survive outages • Interac$ons with humans including pauses, input • Restartable builds in case of transient errors • Reusable defini$ons to avoid duplica=on • Comprehensible scripts with one clear defini=on ©2014 CloudBees, Inc. All Rights Reserved 21
  • 23. Production Release Available NOW! • Jenkins OSS – Workflow 1.0 released December 3 • Beta out since May, with great, engaged feedback • Install Workflow: Aggregator in LTS 1.580.x or a later weekly release • Jenkins Enterprise by CloudBees – Automa=cally available as of the 14.11 release ©2014 CloudBees, Inc. All Rights Reserved 23
  • 24. Demo Time! ©2014 CloudBees, Inc. All Rights Reserved 24
  • 25. Key Features • En=re flow is one concise Groovy script – For loops, try-­‐finally, fork-­‐join … • Can restart Jenkins while flow is running • Allocate slave nodes and workspaces – As many as you want, when you want • Stages throdle concurrency of builds • Human input/approval integrated into flow • Standard project concepts: SCM, ar=facts, plugins ©2014 CloudBees, Inc. All Rights Reserved 25
  • 26. Groovy DSL vs. Graphical Workflow • Familiar control flow construc=on • Familiar “tools” for building abstrac=ons Func=ons, classes, variables, … • Workflow in version control • As opposed to: Graphical workflow designer ©2014 CloudBees, Inc. All Rights Reserved 26
  • 27. Project Setup • One workflow is defined as a job • Single script for all steps • Build triggers & parameters like regular projects • Each workflow execu=on is a regular Jenkins build displayed in regular Jenkins views • Graphical visualiza=on of actual build possible Not of visualiza=on job defini=on but of build execu=on ©2014 CloudBees, Inc. All Rights Reserved 27
  • 28. Non-Sequential Logic timeout(time: 300, unit: 'SECONDS') { } try {} catch {} ©2014 CloudBees, Inc. All Rights Reserved 28
  • 29. Interaction with Humans ©2014 CloudBees, Inc. All Rights Reserved 29
  • 30. Restartable Build / Checkpoint ©2014 CloudBees, Inc. All Rights Reserved 30
  • 31. Visualization ©2014 CloudBees, Inc. All Rights Reserved 31
  • 32. Stages • Semaphore • Visualiza=on ©2014 CloudBees, Inc. All Rights Reserved 32
  • 33. Comprehensible Scripts ©2014 CloudBees, Inc. All Rights Reserved 33
  • 34. Workflow Syntax Card ©2014 CloudBees, Inc. All Rights Reserved 34
  • 35. Workflow Syntax Card • stage: Enter a new stage • node: Allocate node • ws: Allocate workspace • parallel: Execute sub-­‐workflow in parallel • retry: Retry the body up to N =mes • catchError: Catch error and con=nue • timeout: Execute the body with a =meout • input: Input / human interac=on ©2014 CloudBees, Inc. All Rights Reserved 35
  • 36. Workflow Syntax Card • load: Evaluate a Groovy source file into the workflow script • step: General build step • sh: Shell script • bat: Windows batch script ©2014 CloudBees, Inc. All Rights Reserved 36
  • 37. Workflow Syntax Card • archive: Archive ar=facts • unarchive: Copy archived ar=fact into the workspace • echo: Print message • dir: Change directory • readFile: Read file from workspace • writeFile: Write file to workspace ©2014 CloudBees, Inc. All Rights Reserved 37
  • 38. Workflow Syntax Card • git: Git • svn: Subversion • scm: General SCM • tool: install a tool • build: Build a job ©2014 CloudBees, Inc. All Rights Reserved 38
  • 39. Workflow Syntax Card • checkpoint: capture the state of the execu=on so that it can be restarted later ©2014 CloudBees, Inc. All Rights Reserved 39
  • 40. Possible Futures ©2014 CloudBees, Inc. All Rights Reserved 40
  • 41. Possible Futures Probably OSS • More plugin interoperability • Mul=-­‐branch project (& SCM API) integra=on • More advanced SCM • In-­‐IDE edi=ng support • Concise syntax ©2014 CloudBees, Inc. All Rights Reserved 41
  • 42. Possible Futures Probably CloudBees Jenkins Enterprise and Operations Center • More visualiza=ons • Validated merge integra=on • Deployment, incl. blue/green with rollback • Freestyle and/or Build Flow import • Templates integra=on ©2014 CloudBees, Inc. All Rights Reserved 42
  • 43. Get The Code • hdps://gist.github.com/cyrille-­‐leclerc/0dc73659e6d2a92f014a – workflow.groovy • hdps://github.com/cyrille-­‐leclerc/spring-­‐petclinic/ ©2014 CloudBees, Inc. All Rights Reserved 43
  • 44. More Workflow Resources • Tutorial – hdps://github.com/jenkinsci/workflow-­‐ plugin/blob/master/TUTORIAL.md • Jenkins Enterprise by CloudBees Workflow-­‐related Func=onality – hdp://jenkins-­‐enterprise.cloudbees.com/ docs/user-­‐guide-­‐docs/workflow.html • More webinars ©2014 CloudBees, Inc. All Rights Reserved 44
  • 45. Cyrille Le Clerc Director, Product Management [email protected] @cyrilleleclerc Steve Harris SVP, Products [email protected] @stevengharris ©2014 CloudBees, Inc. All Rights Reserved 45
  • 46. ©2014 CloudBees, Inc. All Rights Reserved 46