Building a Continuous Delivery pipeline with Gradle and Jenkins
Continuous Development Pipeline
-
Upload
izzet-mustafaiev -
Category
Software
-
view
1.546 -
download
2
description
Transcript of Continuous Development Pipeline
Continuous Development
Pipeline
● SA at EPAM Systems
● primary skill is Java
● hands-on-coding with Groovy, Ruby
● trying to learn some Erlang/Elixir
● passionate about agile, clean code and devops
Izzet Mustafayev@EPAM Systems@webdizz webdizz izzetmustafaievhttp://webdizz.name
Agenda● Introduction
● Step-by-step Implementation
■ Gradle
■ SonarQube
■ Jenkins
■ Ansible
● References
● Summary
● Q&A
Introduction
Continuous Integration
Principles
#1 Each change auto. built and deployed
#2 Test on closed to prod environment
Principles
#1 Each change auto. built and deployed
#2 Test on closed to prod environment
#1 Each change auto. built and deployed
#3 Integrate as frequently as possible
Principles
#2 Test on closed to prod environment
#1 Each change auto. built and deployed
#3 Integrate as frequently as possible
Principles
#4 The highest priority to fix failed build
Benefits● Each change guarantees working code
● Each update should guarantee working
code ;)
● There is no delay for epic merge
● Less bugs - depends on your tests
efficiency*
● Allows to have code ready to go live
Challenges● Need to build infrastructure
● Need to build team culture
● Need to support/enhance infrastructure
● Overhead with writing a lot of different
kind of tests
Continuous Delivery
Principles
#1 Every commit can result in a release
Principles
#1 Every commit can result in a release
#2 Automated tests are essential
Principles
#1 Every commit can result in a release
#2 Automated tests are essential
#3 Automate everything!
Principles
#1 Every commit can result in a release
#2 Automated tests are essential
#3 Automate everything!
#4 Done means released
Benefits● Speed of delivery of business idea to
customer
● Easy going live deployment
● Less time spent on delivery - more profit
● More motivation to do more as you can
see what you can change/improve
Challenges● Big effort to implement changes for:
○ database increment/rollback
○ infrastructure rollout/rollback
○ decrease down time …
● Need to get customers to buy in
● Security policies
Step-by-step Implementation
Continuous Development?
Gradle
2.2.1
Gradle- General purpose build system
Gradle- General purpose build system
- Comes with a rich DSL based on Groovy
Gradle- General purpose build system
- Comes with a rich DSL based on Groovy
- Follows ”build-by-convention” principles
Gradle- General purpose build system
- Comes with a rich DSL based on Groovy
- Follows ”build-by-convention” principles
- Built-in plug-ins for JVM languages, etc
Gradle- General purpose build system
- Comes with a rich DSL based on Groovy
- Follows ”build-by-convention” principles
- Built-in plug-ins for JVM languages, etc
- Declarative builds
Demo Time
CodeQuality
Ad-hoc, fast feedback
Ad-hoc, fast feedback
Over time
SonarQube- Measures code quality from day #0
SonarQube- Measures code quality from day #0
- 7 axes of code quality
SonarQube- Measures code quality from day #0
- 7 axes of code quality
- Helps to manage Technical Dept
SonarQube- Measures code quality from day #0
- 7 axes of code quality
- Helps to manage Technical Dept
- Works not only for Java
SonarQube- Measures code quality from day #0
- 7 axes of code quality
- Helps to manage Technical Dept
- Works not only for Java
- Good for dev, qa, archs & manager
Demo Time
Jenkins
Jenkins- Distributed builds
Jenkins- Distributed builds
- Plugin Support
Jenkins- Distributed builds
- Plugin Support
- Easy installation, configuration
Jenkins- Distributed builds
- Plugin Support
- Easy installation, configuration
- Strong community and eco-system
Notifications
Email sucks
Who cares?
During a day
End of day
Demo Time
Ansible
Ansible- Agentless
Ansible- Agentless
- SSH as a protocol, requires only Python
Ansible- Agentless
- SSH as a protocol, requires only Python
- YAML based configuration
Ansible- Agentless
- SSH as a protocol, requires only Python
- YAML based configuration
- Declarative and Decentralized
Ansible- Agentless
- SSH as a protocol, requires only Python
- YAML based configuration
- Declarative and Decentralized
- Built-in security and encryption
Demo Time
Summary
Summary ● Culture is quite important
Summary ● Culture is quite important
● Automation is a thing
Summary ● Culture is quite important
● Automation is a thing
● Automated Testing is even more thing
Summary ● Culture is quite important
● Automation is a thing
● Automated Testing is even more thing
● Continuous process
References
●
●
● http://www.gradle.org/books
● https://github.com/Netflix/gradle-template
● http://www.ansible.com/
● http://www.sonarqube.org/
● http://jenkins-ci.org/
● https://github.com/webdizz/bootiful-apps/
● https://github.com/webdizz/gradle-template
● https://github.com/eliogrin/CISEN/
References
Q&A
Izzet Mustafayev@EPAM Systems@webdizz webdizz izzetmustafaievhttp://webdizz.name