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
[deSymfony] Trovit Deployment pipeline
Search
albertplaya
September 16, 2016
Technology
0
450
[deSymfony] Trovit Deployment pipeline
Trovit Deployment pipeline using ansible and jenkins pipeline
albertplaya
September 16, 2016
Tweet
Share
Other Decks in Technology
See All in Technology
20241218_今年はSLI/SLOの導入を頑張ってました!
zepprix
0
250
クレカ・銀行連携機能における “状態”との向き合い方 / SmartBank Engineer LT Event
smartbank
3
130
MasterMemory v3 最速確認会
yucchiy
0
290
事業貢献を考えるための技術改善の目標設計と改善実績 / Targeted design of technical improvements to consider business contribution and improvement performance
oomatomo
0
240
OCI技術資料 : ファイル・ストレージ 概要
ocise
3
12k
20241220_S3 tablesの使い方を検証してみた
handy
4
850
ネットワーク可視化の世界
likr
7
5.6k
TSKaigi 2024 の登壇から広がったコミュニティ活動について
tsukuha
0
180
12 Days of OpenAIから読み解く、生成AI 2025年のトレンド
shunsukeono_am
0
970
効率的な技術組織が作れる!書籍『チームトポロジー』要点まとめ
iwamot
2
190
PHPerのための計算量入門/Complexity101 for PHPer
hanhan1978
6
1.5k
非機能品質を作り込むための実践アーキテクチャ
knih
6
1.8k
Featured
See All Featured
GraphQLとの向き合い方2022年版
quramy
44
13k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
33
2.7k
Designing Dashboards & Data Visualisations in Web Apps
destraynor
230
52k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
PRO
10
850
Rails Girls Zürich Keynote
gr2m
94
13k
Building Flexible Design Systems
yeseniaperezcruz
328
38k
Practical Orchestrator
shlominoach
186
10k
Designing for Performance
lara
604
68k
Code Reviewing Like a Champion
maltzj
521
39k
Designing Experiences People Love
moore
139
23k
Intergalactic Javascript Robots from Outer Space
tanoku
270
27k
The Art of Programming - Codeland 2020
erikaheidi
53
13k
Transcript
Presentation styleguide May 2016
Presentation styleguide May 2016
TROVIT & DEPLOYMENT OVERVIEW TROVIT DEPLOYMENT SYSTEM (PAST, PRESENT AND
FUTURE) ADVICE
TROVIT & DEPLOYMENT OVERVIEW TROVIT DEPLOYMENT SYSTEM (PAST, PRESENT AND
FUTURE) ADVICE
A CLASSIFIED SEARCH ENGINE FOR PROPERTY, JOBS, CARS AND PRODUCTS
None
None
PLATFORM NUMBERS 5 SERVERS 40 SERVERS 20 SERVERS 4 SERVERS
50 SERVERS 400 SERVERS
Deployment
Build
Synchronization
Release
TROVIT & DEPLOYMENT OVERVIEW TROVIT DEPLOYMENT SYSTEM (PAST, PRESENT AND
FUTURE) ADVICE
Trovit deployment system (Past, present and future)
Old deployment system
BUILD CREATION Build host Internal External Services Commands SATIS
OLD TROVIT DEPLOYMENT - BUILD 1 PROJECT PROJECT FRAMEWORK symlink
✔ BUILD SIZE ✘ BUILD DEPENDENCY ✘ QA INSECURITY
OLD TROVIT DEPLOYMENT - BUILD X PROJECTS PROJECT 1 FRAMEWORK
symlink PROJECT 2 symlink PROJECT 3 symlink
✔ BUILD SIZE ✘ DEPENDENCY ✘ QA INSECURITY ✘ COMPLEXITY
✘ COMMUNICATION ✘ C&P BASH SCRIPTS ✘ CHANGELESS OLD TROVIT DEPLOYMENT - BUILD X PROJECTS
DEPLOYMENT WITHOUT SYMBOLIC LINK Deployment host tag ../project/ ../project/
DEPLOYMENT WITHOUT SYMBOLIC LINK ✔ UPLOAD ONLY MODIFIED FILES (rsync)
✘ SLOW ROLLBACK ✘ ERRORS 500! ✘ SERVERS WITH DIFFERENT VERSIONS
DEPLOYMENT WITH SYMBOLIC LINK Deployment host tag ../project/ ../project/releases/tag ../project/current
Symbolic link Full copy
DEPLOYMENT WITH SYMBOLIC LINK ✔ FAST VERSION INSTALLATION ✔ SERVERS
WITH THE SAME VERSION ✔ IMMEDIATE ROLLBACK ✔ AVOID ANY ERRORS DURING THE DEPLOY ✘ SLOW UPLOAD
RELEASE • Change symbolik link (with symbolic link ) •
Php bin/console cache:clear --env=prod --no-debug • Clean opcache • Apache graceful
Sum up
DEPLOYMENT SYSTEM OVERVIEW • Copy-Paste. • Poor design (rigidity, fragility,
immobility, viscosity). • Command line execution. • Slow deploys (20 minutes!!!). • Multi builds for different environments. • Some projects with releases and others without. • Production errors!
Current deployment system
Vision
10 BACKEND TEAMS +15 PHP PROJECTS
None
+
+
ABOUT ANSIBLE App deployment, configuration management and orchestration. • Minimal
in nature • Consistent • Secure • Highly reliable • Low learning curve INFRASTRUCTURE AS CODE • Cost reduction • Faster execution • Remove errors and security violations
HOW ANSIBLE WORKS?
ANSIBLE STRUCTURE
INVENTORY
PROJECT
ROLES
https://docs.ansible.com/ansibl e/deploy_helper_module.html DEPLOY HELPER
FOLDER STRUCTURE
EXAMPLE
JENKINS OVERVIEW
JENKINS PROGRAM
None
CONTINUOUS DELIVERY DEPLOYMENT PIPELINE CODE REVIEW QA OR DEVELOPER BUILD
PREPRODUCTION PRODUCTION
BUILD Execute ansible playbook Execute all the roles Tag: X.X.X
Get tags
BUILD
PRODUCTION Get tags Tag: X.X.X DEPLOYMENT ENVIRONMENT
DEPLOYMENT ENVIRONMENT
UI DEPLOYMENT PIPELINE
UI DEPLOYMENT PIPELINE
PIPELINE DSL (GROOVY)
JENKINS TROVIT BUILDS
JENKINS TROVIT DEPLOYMENT
Rollback
Future
AGILE WORKFLOW CONTINUOUS INTEGRATION CONTINUOUS DELIVERY CONTINUOUS DEPLOYMENT
PIPELINE SCALABILITY
QA WORKFLOW QA SYSTEM TO BE TESTED AUTOMATED TESTING PRACTICES
TESTING PLATFORM TEST ADMINISTRA TOR TESTING TOOLS TEST LIBRARY
SERVICE CONTAINER
CONTAINER DEPLOYMENT LOAD BALANCER WEB SERVER APP SERVER DATABASES
WIKI • ANSIBLE: https://www.ansible.com/ • ANSIBLE DEPLOY HELPER: https://docs.ansible.com/ansible/deploy_helper_module.html •
JENKINS: https://jenkins.io/solutions/pipeline • BLUE GREEN DEPLOYMENT: http://martinfowler.com/bliki/BlueGreenDeployment.html • KUBERNETES: http://kubernetes.io/ • DOCKER: https://www.docker.com/ • NETFLIX: http://techblog.netflix.com/2015/11/global-continuous-delivery-with.html • ETSY: https://www.infoq.com/news/2014/03/etsy-deploy-50-times-a-day • CONTINUOUS INTEGRATION VS CONTINUOUS DELIVERY VS CONTINUOUS DEPLOYMENT: http://stackoverflow.com/questions/28608015/continuous-integration-vs-continuous-delivery-vs-continuou s-deployment • PMP: https://en.wikipedia.org/wiki/Project_Management_Body_of_Knowledge • TROVIT: https://www.youtube.com/channel/UCz8S73iKoCom2RN8B8l-Heg • TROVIT CAREERS: http://careers.trovit.com/
TROVIT & DEPLOYMENT OVERVIEW TROVIT DEPLOYMENT SYSTEM (PAST, PRESENT AND
FUTURE) ADVICE
Advice
GLOBAL VISION SCOPE COST TIME
GLOBAL VISION RISK QUALITY STAKEHOLDERS INTEGRATION COMMUNICATION
None
Albert Playà (@albertplaya) Software Development Manager
QUESTIONS?