Thanks to visit codestin.com
Credit goes to www.slideshare.net

Jenkins User Conference Israel #jenkinsconf 
Building a deployment 
Noam Shochat 
@noamshochat 
eToro 
www.etoro.com 
July 16, 2014 
pipeline 
#jenkinsconf
Amount of 
Work 
Time 
Current 
Reality 
What we think 
will happen 
Adding automation
A little bit about eToro 
● 120 Services 
● 300 Servers 
● 3 Data centers 
● 2 Clouds 
● .Net 
●
The problem 
● Builds 
● Manual deployments 
● Lack of uniformity 
● Different OS’s 
● Slowness 
● Different Environments 
● Security 
Developer Production
The Solution 
Code commit 
CI / CD 
Production Build, Unit tests 
Deploy and tests in QA
We choose Jenkins 
BUT… 
Not good for: 
● Deployment 
● Orchestration
So we also choose to use: 
● Mcollective + Ruby for orchestration 
● Puppet for deployment (and more) 
● RabbitMQ for connecting between them
Pipeline 
Commit 
Build Unit tests Trigger 
ruby 
Developer 
QA - Jenkins 
Servers 
Puppet 
Puppet 
Puppet 
Integration 
tests 
Production - Jenkins 
Servers 
Puppet 
Puppet 
Puppet 
Trigger 
MCollective 
Trigger 
MCollective 
Trigger 
ruby
In Jenkins
Flow
Flow 
out.println 'Starting OpenBookSearchAPI Flow' 
b=build("OpenBookSearchAPI-Build") 
parallel( 
{ 
build("OpenbookSearchAPIBack-iis") 
}, 
{ 
build("OpenbookSearchAPI-Service-Stop") 
build("OpenbookSearchAPI-Service") 
build("OpenbookSearchAPI-Service-Start") 
} 
)
Build
Build 
● Mercurial 
● Build start by trigger 
● MSBuild 
● NUnit tests + dot cover
Deployment
Deployment 
● Use Ruby for trigger and orchestrate using 
MCollective 
● Puppet do the deployment
Integration tests
Integration tests 
● Canary tests
Health check
Health check 
● What is it? 
● Json file that checks dependencies and 
basic sanity test
Publish
Publish 
● Almost in production 
● Build version file as the gatekeeper to 
production
Production deploy 
● Build version file 
● rsync
CloudShare 
● Jenkins CLI 
● Dynamic jenkins agents 
● The flow continue the same changes to 
same flow
Plugins we’re using 
● MSBuild 
● HTML Publisher 
● Nested View 
● Build Flow 
● Active directory 
● statsd
Our CI/CD servers 
Jenkins 
master 
+ MCollective RabbitMQ WebApp 
Servers 
Puppet 
master 
Ruby 
script
Q&A
Jenkins User Conference Israel #jenkinsconf 
Thank You To Our Sponsors 
Platinum 
Gold 
Silver

Building a deployment pipeline

  • 1.
    Jenkins User ConferenceIsrael #jenkinsconf Building a deployment Noam Shochat @noamshochat eToro www.etoro.com July 16, 2014 pipeline #jenkinsconf
  • 2.
    Amount of Work Time Current Reality What we think will happen Adding automation
  • 3.
    A little bitabout eToro ● 120 Services ● 300 Servers ● 3 Data centers ● 2 Clouds ● .Net ●
  • 4.
    The problem ●Builds ● Manual deployments ● Lack of uniformity ● Different OS’s ● Slowness ● Different Environments ● Security Developer Production
  • 5.
    The Solution Codecommit CI / CD Production Build, Unit tests Deploy and tests in QA
  • 6.
    We choose Jenkins BUT… Not good for: ● Deployment ● Orchestration
  • 7.
    So we alsochoose to use: ● Mcollective + Ruby for orchestration ● Puppet for deployment (and more) ● RabbitMQ for connecting between them
  • 8.
    Pipeline Commit BuildUnit tests Trigger ruby Developer QA - Jenkins Servers Puppet Puppet Puppet Integration tests Production - Jenkins Servers Puppet Puppet Puppet Trigger MCollective Trigger MCollective Trigger ruby
  • 9.
  • 10.
  • 11.
    Flow out.println 'StartingOpenBookSearchAPI Flow' b=build("OpenBookSearchAPI-Build") parallel( { build("OpenbookSearchAPIBack-iis") }, { build("OpenbookSearchAPI-Service-Stop") build("OpenbookSearchAPI-Service") build("OpenbookSearchAPI-Service-Start") } )
  • 12.
  • 13.
    Build ● Mercurial ● Build start by trigger ● MSBuild ● NUnit tests + dot cover
  • 14.
  • 15.
    Deployment ● UseRuby for trigger and orchestrate using MCollective ● Puppet do the deployment
  • 16.
  • 17.
  • 18.
  • 19.
    Health check ●What is it? ● Json file that checks dependencies and basic sanity test
  • 20.
  • 21.
    Publish ● Almostin production ● Build version file as the gatekeeper to production
  • 22.
    Production deploy ●Build version file ● rsync
  • 23.
    CloudShare ● JenkinsCLI ● Dynamic jenkins agents ● The flow continue the same changes to same flow
  • 24.
    Plugins we’re using ● MSBuild ● HTML Publisher ● Nested View ● Build Flow ● Active directory ● statsd
  • 25.
    Our CI/CD servers Jenkins master + MCollective RabbitMQ WebApp Servers Puppet master Ruby script
  • 26.
  • 27.
    Jenkins User ConferenceIsrael #jenkinsconf Thank You To Our Sponsors Platinum Gold Silver