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
A Pragmatic Approach to Rails Deployments and O...
Search
technicalpickles
May 28, 2012
Technology
2
450
A Pragmatic Approach to Rails Deployments and Operations
Lessons learned from deploying and managing hundreds of Rails applications
technicalpickles
May 28, 2012
Tweet
Share
Other Decks in Technology
See All in Technology
フルカイテン株式会社 採用資料
fullkaiten
0
40k
【Startup CTO of the Year 2024 / Audience Award】アセンド取締役CTO 丹羽健
niwatakeru
0
870
ExaDB-D dbaascli で出来ること
oracle4engineer
PRO
0
3.8k
第1回 国土交通省 データコンペ参加者向け勉強会③- Snowflake x estie編 -
estie
0
120
開発生産性を上げながらビジネスも30倍成長させてきたチームの姿
kamina_zzz
2
1.7k
EventHub Startup CTO of the year 2024 ピッチ資料
eventhub
0
110
いざ、BSC討伐の旅
nikinusu
2
780
誰も全体を知らない ~ ロールの垣根を超えて引き上げる開発生産性 / Boosting Development Productivity Across Roles
kakehashi
1
220
信頼性に挑む中で拡張できる・得られる1人のスキルセットとは?
ken5scal
2
530
New Relicを活用したSREの最初のステップ / NRUG OKINAWA VOL.3
isaoshimizu
2
570
スクラムチームを立ち上げる〜チーム開発で得られたもの・得られなかったもの〜
ohnoeight
2
350
【令和最新版】AWS Direct Connectと愉快なGWたちのおさらい
minorun365
PRO
5
750
Featured
See All Featured
KATA
mclloyd
29
14k
What's new in Ruby 2.0
geeforr
343
31k
Into the Great Unknown - MozCon
thekraken
32
1.5k
ピンチをチャンスに:未来をつくるプロダクトロードマップ #pmconf2020
aki_iinuma
109
49k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
232
17k
What's in a price? How to price your products and services
michaelherold
243
12k
No one is an island. Learnings from fostering a developers community.
thoeni
19
3k
Six Lessons from altMBA
skipperchong
27
3.5k
Why You Should Never Use an ORM
jnunemaker
PRO
54
9.1k
Building Applications with DynamoDB
mza
90
6.1k
Designing for humans not robots
tammielis
250
25k
Thoughts on Productivity
jonyablonski
67
4.3k
Transcript
Lessons learned from deploying and managing hundreds of Rails applications
A Pragmatic Approach to Rails Deployments and Operations Monday, May 28, 12
Lessons learned from deploying and managing hundreds of Rails applications
Rails Deployments and Operations Monday, May 28, 12
o hai, im josh Monday, May 28, 12
•@techpickles •http://github.com/technicalpickles •http://technicalpickles.com Monday, May 28, 12
Monday, May 28, 12
Awesomeness Engineer of Supreme Versatility III Monday, May 28, 12
Managed hosting and operations Monday, May 28, 12
I’m talking about Rails Operations Monday, May 28, 12
WTF is Rails Operations? Monday, May 28, 12
Development and maintenance of a production Rails application Monday, May
28, 12
Before we dig in too deep... Monday, May 28, 12
Monday, May 28, 12
Does development generate revenue? Question Monday, May 28, 12
Monday, May 28, 12
•Takes place on laptops, desktop machines, staging servers Monday, May
28, 12
•Takes place on laptops, desktop machines, staging servers •No real
users Monday, May 28, 12
•Takes place on laptops, desktop machines, staging servers •No real
users •Unknown if it truly works Monday, May 28, 12
•Takes place on laptops, desktop machines, staging servers •No real
users •Unknown if it truly works •Tests are green, but... Monday, May 28, 12
Monday, May 28, 12
•Step 1: Development Monday, May 28, 12
•Step 1: Development •Step 2: Operations Monday, May 28, 12
•Step 1: Development •Step 2: Operations •Step 3: ...... Monday,
May 28, 12
•Step 1: Development •Step 2: Operations •Step 3: ...... •Step
4: PROFIT! Monday, May 28, 12
NO Monday, May 28, 12
but it CREATES potential revenue Monday, May 28, 12
Monday, May 28, 12
•Step 1: Development Monday, May 28, 12
•Step 1: Development •Step 2: ....... Monday, May 28, 12
•Step 1: Development •Step 2: ....... •Step 3: PROFIT Monday,
May 28, 12
Does operations generate revenue? Question Monday, May 28, 12
Monday, May 28, 12
•Lives on servers located in data centers and clouds Monday,
May 28, 12
•Lives on servers located in data centers and clouds •Real
users Monday, May 28, 12
•Lives on servers located in data centers and clouds •Real
users •Either code works, or it doesn’t Monday, May 28, 12
•Lives on servers located in data centers and clouds •Real
users •Either code works, or it doesn’t •Either the application is available or not Monday, May 28, 12
NO Monday, May 28, 12
but it PRESERVES potential revenue Monday, May 28, 12
Uh, what generates revenue? Question Monday, May 28, 12
Million Dollar Question Monday, May 28, 12
Monday, May 28, 12
•Working features (or at least that work enough) Monday, May
28, 12
•Working features (or at least that work enough) •Infrastructure to
keep the application up and running (or at least up enough) Monday, May 28, 12
•Working features (or at least that work enough) •Infrastructure to
keep the application up and running (or at least up enough) •A business model that works (or at least works enough) Monday, May 28, 12
•Working features (or at least that work enough) •Infrastructure to
keep the application up and running (or at least up enough) •A business model that works (or at least works enough) •??????????????????????? Monday, May 28, 12
Lessons learned Monday, May 28, 12
Common threads Monday, May 28, 12
Monday, May 28, 12
Monday, May 28, 12
Monday, May 28, 12
Pattern Configuration Management Monday, May 28, 12
duh. It’s about managing configuration. Monday, May 28, 12
You write code that manages your servers’ configuration Monday, May
28, 12
Monday, May 28, 12
•apache package is installed Monday, May 28, 12
•apache package is installed •apache service is running Monday, May
28, 12
•apache package is installed •apache service is running •deploy user
exists Monday, May 28, 12
•apache package is installed •apache service is running •deploy user
exists •cron jobs Monday, May 28, 12
•apache package is installed •apache service is running •deploy user
exists •cron jobs •etc Monday, May 28, 12
•Puppet •Chef •Moonshine Monday, May 28, 12
Automation Monday, May 28, 12
Monday, May 28, 12
Monday, May 28, 12
Pattern Staging Environments Monday, May 28, 12
Preproduction servers Monday, May 28, 12
Gives you a place to ensure correctness of deploy Monday,
May 28, 12
configuration management + staging servers = VERY YES Monday, May
28, 12
Monday, May 28, 12
Monday, May 28, 12
Repeat after me Monday, May 28, 12
Repeat after me • development Monday, May 28, 12
Repeat after me • development • staging Monday, May 28,
12
Repeat after me • development • staging • production Monday,
May 28, 12
capistrano-gitflow Monday, May 28, 12
Pattern Deploy early, deploy often Monday, May 28, 12
Although technically, I guess it’s the same A play on
release early, release often. Monday, May 28, 12
Monday, May 28, 12
Monday, May 28, 12
Antipattern Feeling Driven Development Monday, May 28, 12
Monday, May 28, 12
The front page feels slow Monday, May 28, 12
The primary key seems like it’s increasing rapidly Monday, May
28, 12
IO seems high Monday, May 28, 12
What does it even mean? Monday, May 28, 12
Counterpattern Science Driven Development Monday, May 28, 12
Monday, May 28, 12
Metrics everywhere! Monday, May 28, 12
•New Relic - http://newrelic.com •Scout - http://scoutapp.com Monday, May 28,
12
The front page is taking 10 seconds to load, but
we really need it to be loading in under 1 second The front page feels slow Monday, May 28, 12
The primary key is at 90% of it’s maximum, up
from 80% yesterday, and looks like it’ll run out overnight. The primary key seems like it’s increasing rapidly Monday, May 28, 12
IO fluctuates up to 90% sometimes, but doesn’t appear to
have a negative effect IO seems high Monday, May 28, 12
Monday, May 28, 12
Topic Monitoring Monday, May 28, 12
How do you know when everything is awful? Monday, May
28, 12
How would you prefer to know? Monday, May 28, 12
How would you prefer to know? •A late night phone
call? Monday, May 28, 12
How would you prefer to know? •A late night phone
call? •Angry tweets that you are down? Monday, May 28, 12
How would you prefer to know? •A late night phone
call? •Angry tweets that you are down? •You personally checking everything all the time? Monday, May 28, 12
How would you prefer to know? •A late night phone
call? •Angry tweets that you are down? •You personally checking everything all the time? •An automated system to let you know? Monday, May 28, 12
•Nagios •Scout •New Relic •Pingdom Monday, May 28, 12
What to monitor Monday, May 28, 12
Define urgency Monday, May 28, 12
Must be actionable Monday, May 28, 12
Single point of contact Monday, May 28, 12
Monday, May 28, 12
Pattern Vertical scaling Monday, May 28, 12
Now what? Your app is slow Monday, May 28, 12
Monday, May 28, 12
Resources are (relatively) cheap Monday, May 28, 12
Developers are (relatively) expensive Monday, May 28, 12
Monday, May 28, 12
Monday, May 28, 12
Antipattern Hipster Stack Monday, May 28, 12
Monday, May 28, 12
“I read a blog post about how mongo is totally
web scale” Monday, May 28, 12
Cargo cult operations Monday, May 28, 12
Monday, May 28, 12
Monday, May 28, 12
Monday, May 28, 12
If you’re still going to go hipster... •experiment in branches
•understand operational impact •Staging! Monday, May 28, 12
.... wait, what? Test in production Monday, May 28, 12
Fin. Monday, May 28, 12
Further Reading •Web Operations - John Allspaw and Jesse Robins
•Continuous Delivery - Jez Humble and David Farley •“Web Operations for Developers 101” Monday, May 28, 12
find me here
[email protected]
@techpickles Want to talk ops? Monday,
May 28, 12