Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
X tips [X==9] for building a Bulletproof Deployment Pipeline with Jenkins
Search
oshai
July 13, 2017
Technology
0
32
X tips [X==9] for building a Bulletproof Deployment Pipeline with Jenkins
JUC 2017 presentation
oshai
July 13, 2017
Tweet
Share
More Decks by oshai
See All by oshai
Maintaining an Open Source The Good, Bad & Ugly
oshai
0
26
KScript
oshai
0
13
Klean Code with Kotlin
oshai
0
52
JVM languages shootout - Java, Scala & *Kotlin*
oshai
0
32
Koroutinify ; Lessons learned from applying Coroutines in Kotlin Backend ; Deep dive into Coroutines
oshai
1
94
Klean that Code, Boil those Boilerplates
oshai
2
54
Scala vs. Kotlin; Friend or Foe?
oshai
0
160
No forks, One star. Now what?! — How I published my Kotlin Open-Source lib
oshai
0
58
Scala--pack your Future[T]; Kotlin is coming! (Kotlin TLV)
oshai
0
160
Other Decks in Technology
See All in Technology
初心者が行く!サーバレスWebアプリ開発の道
nagaharutogawa
0
450
8週連続ウェビナー_イチから学ぶFivetran
cmsuzu
0
170
Vos logs méritent mieux que la config par défaut
lyrixx
2
380
ビジネスとコード品質の接合点 そしてコード品質がそこに及ぼす影響 / The Intersections of Business and Engineering, and The Impact of Code Quality There
mtx2s
10
1k
これまでのキャリアとこれからMLエンジニアとしてどう動くか
masatakashiwagi
1
570
技育祭2024春 LT Finatextホールディングス
kevinrobot34
1
170
統計的学習理論読み Chapter 2
kmatsui
1
270
単回帰分析について数式を追いながら実装してみた
kentaitakura
0
500
Building a RAG app to chat with your data (on Azure)
pamelafox
0
120
エバンジェリスト活動を7年やってきて見えてきた、コミュニティとエバンジェリストの関係
soracom
PRO
1
200
Cloud Friendly(?) Jenkins. How we failed to make Jenkins cloud native and what we learned?
onenashev
PRO
0
110
LLM + RAG を使った SORACOM Support Bot の裏側の歴史
soracom
PRO
1
640
Featured
See All Featured
The Invisible Customer
myddelton
114
12k
The Cult of Friendly URLs
andyhume
73
5.6k
Designing with Data
zakiwarfel
94
4.8k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
124
32k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
6
950
Intergalactic Javascript Robots from Outer Space
tanoku
266
26k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
11
1.4k
jQuery: Nuts, Bolts and Bling
dougneiner
57
7.1k
10 Git Anti Patterns You Should be Aware of
lemiorhan
644
57k
Optimizing for Happiness
mojombo
369
69k
WebSockets: Embracing the real-time Web
robhawkes
59
6.9k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
113
18k
Transcript
X tips [X==9] for building a Bulletproof Deployment Pipeline with
Jenkins JULY 13 / TLV, Israel Ohad Shai Software Engineer && Team Leader @ Outbrain
About Me • Developing Software since 2005 • Mainly in
Java and JVM languages • Works on backend systems • Using Jenkins since 2011 • Co-author of codeine open-source tool for Continuous Deployment on large scale
Deployment Pipeline • The driver tool for Continuous-Delivery • Features:
• Complex build flows • Job as a Code (aka JenkinsFile) • Suspend/Resume and survive restarts of Jenkins
Tip #1 You should have done this ages ago •
Define
Tip #2 Start simple
Tip #3 Use Blue Ocean view
Tip #4 Validate artifacts and source code consistency across pipeline
Tip #5 Use commit hook with message regex gitCommitMessage =
sh(returnStdout: true, script: 'git log -1 --pretty=%B').trim() deployToProd = (gitCommitMessage =~ /#d2p/ || params.DEPLOY_TAG == "#d2p") //we also allow '#d2p' when triggering manually
Tip #6 pipeline { agent { docker 'maven:3-alpine' } stages
{ stage('Example Build') { steps { sh 'mvn -B clean verify' } } } } node { stage('Example') { try { sh 'exit 1' } catch (exc) { echo 'Something failed, I should sound the klaxons!' throw exc } } } Declarative Pipeline Scripted Pipeline
Tip #7 Ask for user authorization on sensitive operations timeout(time:5,
unit:'HOURS') { input message: ‘Deploy to production?', ok: 'Deploy!' } http://jenkins508.rssing.com/chan-25443405/all_p18.html
Tip #8 Integrate slack
Tip #9 Make the pipeline fast stage("Testing: phase a") {
parallel 'JUnit': { stage("junit") { sh '...' } }, 'Deploy to simulator': { stage("Deploy to simulator") { sh '...' } } }
Bonus Tip Noise Cancelling Headphones
Questions? Wanna try it? We’re hiring!
Questions? Wanna try it? We’re hiring!
Enjoy piping! https://weeklygravy.com/fashion-grooming/how-old-do-you-have-to-be-before-you-can-smoke-a-pipe/ @OhadShai