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
Heroku101 Kanazawa
Search
Keiko Oda
June 21, 2014
Technology
2
550
Heroku101 Kanazawa
Heroku101 for Kanazawa.rb #22
Keiko Oda
June 21, 2014
Tweet
Share
More Decks by Keiko Oda
See All by Keiko Oda
Exploring Postgres VACUUM with the VACUUM Simulator
keiko713
5
14k
Introduction to Netlify
keiko713
1
90
What really happens when you deploy a site on Netlify
keiko713
0
810
Healthy Database
keiko713
2
250
What's wrong with your app?
keiko713
0
300
Intro of Heroku Support
keiko713
0
390
What is Heroku?
keiko713
0
230
Heroku 3mins FAQ
keiko713
0
300
Heroku Support
keiko713
5
3.2k
Other Decks in Technology
See All in Technology
SRE×AIOpsを始めよう!GuardDutyによるお手軽脅威検出
amixedcolor
0
180
Application Development WG Intro at AppDeveloperCon
salaboy
0
190
20241120_JAWS_東京_ランチタイムLT#17_AWS認定全冠の先へ
tsumita
2
300
Lambda10周年!Lambdaは何をもたらしたか
smt7174
2
110
Python(PYNQ)がテーマのAMD主催のFPGAコンテストに参加してきた
iotengineer22
0
510
Why App Signing Matters for Your Android Apps - Android Bangkok Conference 2024
akexorcist
0
130
『Firebase Dynamic Links終了に備える』 FlutterアプリでのAdjust導入とDeeplink最適化
techiro
0
130
オープンソースAIとは何か? --「オープンソースAIの定義 v1.0」詳細解説
shujisado
10
1.1k
ノーコードデータ分析ツールで体験する時系列データ分析超入門
negi111111
0
420
The Role of Developer Relations in AI Product Success.
giftojabu1
0
140
プロダクト活用度で見えた真実 ホリゾンタルSaaSでの顧客解像度の高め方
tadaken3
0
180
OTelCol_TailSampling_and_SpanMetrics
gumamon
1
200
Featured
See All Featured
Product Roadmaps are Hard
iamctodd
PRO
49
11k
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
280
13k
The Cult of Friendly URLs
andyhume
78
6k
Become a Pro
speakerdeck
PRO
25
5k
5 minutes of I Can Smell Your CMS
philhawksworth
202
19k
The Illustrated Children's Guide to Kubernetes
chrisshort
48
48k
Scaling GitHub
holman
458
140k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
232
17k
10 Git Anti Patterns You Should be Aware of
lemiorhan
655
59k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
44
6.8k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
47
5k
Gamification - CAS2011
davidbonilla
80
5k
Transcript
Heroku 101 Keiko Oda (@keiko713) Technical Support Engineer Saturday, June
21, 14
About me ৫ాܟࢠʢ͓͚͍ͩ͜ʣ ੴݝۚࢢग़ ੴߴઐɹిࢠใֶՊଔ 20134݄ɹHerokuೖࣾ ݱࡏۚͷ࣮ՈΑΓϦϞʔτۈ Saturday, June 21,
14
Table of Contents Herokuͬͯʁ (20mins) Πϯετʔϧͯ͠ΈΑ͏ (10mins) σϞ (10mins) ΞϓϦΛσϓϩΠͯ͠ΈΑ͏
(30mins) ΧελϚΠζͯ͠ΈΑ͏ (20mins) Saturday, June 21, 14
What is Heroku? PaaS (Platform as a Service) Heroku༻ޠɹ ଟݴޠରԠ
(Ruby, Java, Node.js, etc.) ๛ͳΞυΦϯ ࢝Ί͍͢ແྉ Saturday, June 21, 14
Heroku ຊࣾɿΞϝϦΧɹαϯϑϥϯγεί ɹ2007 James, Adam, OrionʹΑͬͯઃཱ 2010 Salesforce.com͕ങऩ 2011 Matz͕͖ͨΑ
Saturday, June 21, 14
PaaS IaaS (Infrastracture as a Service) ࣗͰαʔόʔΛ༻ҙ͠ͳ͍͍ͯ͘ʂ SaaS (Software as
a Service) ࣗͰΞϓϦΛ࡞Βͳ͍͍ͯ͘ʂ PaaS (Platform as a Service) ࣗͰαʔόʔͷηοτΞοϓ͠ͳ͍͍ͯ͘ʂ Saturday, June 21, 14
Heroku terms dyno: Heroku্ͰΔΠϯελϯεͷ୯Ґɻࣗ༝ ʹ૿ͨ͠ΓݮΒͨ͠Γग़དྷΔɻαΠζݱࡏ1X, 2X, PX͕͋Δ add-on: ΞϓϦʹՃͰ͖Δ֦ுػೳɻσʔλ ϕʔεͳͲ͕͋Δ
buildpack: ΞϓϦΛσϓϩΠͨ࣌͠ʹΔεΫ Ϧϓτɻ͜͜ͰRubyͳͲΛΠϯελϯεʹೖΕΔ Saturday, June 21, 14
Languages ੲRuby͚ͩͩͬͨ ࠓΦϑΟγϟϧʹ5ݴޠ+αରԠ Ruby, Java, Node.js, Python, PHP ΓRuby͕ࠜڧ͍ਓؾ buildpackʹΑͬͯଞͷݴޠରԠՄೳ
Saturday, June 21, 14
Add-ons Data Stores (heroku postgres) Logging Email Caching Monitoring Saturday,
June 21, 14
Pricing 1ϲ݄ͨΓ750 dyno-hours͕ແྉʂ 24 h * 1 dyno * 30
days = 720 dyno-hours ՝ۚඵ୯ҐʢΞυΦϯؚΉʣ ແྉ͔Β࢝ΊΒΕΔΞυΦϯͨͬΓ ΞυΦϯΛར༻͍ͨ͠߹ͷΈΫϨδοτΧʔυͷొ͕ඞཁ Saturday, June 21, 14
Herokai Japan ·ͭͱ͞Μ ͳ͔ͩ͞Μ ͍͋͟Θ͞Μ ͩ͞͞͞Μ Herokuͷϓϩ ৭ʑ༏͘͠ڭ͑Δϓϩ ύον/σόοάͷϓϩ Ωʔϊʔτͷϓϩ
Saturday, June 21, 14
Let’s install! ֬ೝ1: Heroku toolbeltೖΕ·ͨ͠ʁ ֬ೝ2: Heroku Sign up͠·ͨ͠ʁ ֬ೝ3:
Heroku CLIͰloginͯ͠Έ·ͨ͠ʁ ࣭1: طʹHerokuΛͬͨ͜ͱ͕͋Δʁ ࣭2: GitΛͬͨ͜ͱ͕͋Γ·͔͢ʁ Saturday, June 21, 14
Saturday, June 21, 14
Deploy app to Heroku 1. ΞϓϦΛGitHub͔Βམͱͯ͘͠Δ 2. ϩʔΧϧͰΒͤͯΈΔ 3. git
push heroku master Saturday, June 21, 14
Clone app from GitHub $ git clone https:/ /github.com/keiko713/rails- todo.git
ࠓճ͋·Γ࣌ؒͳ͍ͷͰɺrails newͳ Ͳඈ͠·͢ Saturday, June 21, 14
Run app locally $ cd rails-todo $ bundle install --without
production $ foreman run bundle exec rake db:migrate $ foreman start http://localhost:5000/ Λ։͍ͯΞϓϦ͕ ಈ͍͍ͯΔ͔֬ೝ Saturday, June 21, 14
Deploy $ heroku create # create an app $ git
remote -v # who the list of remotes $ heroku rename <keiko-todo> # rename $ git push heroku master # deploy! $ heroku run rake db:migrate # db migrate $ heroku open # open the app in browser Saturday, June 21, 14
Customize! 0. Add-onΛՃͯ͠ΈΔ 1. Unicornʹͯ͠ΈΔ 2. CSSJSͳͲΛมߋͯ͠ΈΔ 3. ͖ͳͱ͜ΖΛมߋͯ͠ΈΔ Saturday,
June 21, 14
Using add-ons HerokuͷΞυΦϯศརͳͷ͔Γ ࠓճloggingͱmonitoringΛՃ Saturday, June 21, 14
Using Unicorn https://devcenter.heroku.com/articles/ rails-unicorn υΩϡϝϯτʹԊͬͯͬͯΈΔ HerokuͰͷ։ൃϑϩʔ Change git add git
commit git push Saturday, June 21, 14
Modify CSS/JS ࠓͷσβΠϯΠέͯͳ͍ͷͰม͑ͯΈΔ HerokuͰͷ։ൃϑϩʔ Change git add git commit git
push Saturday, June 21, 14
ͦͷଞ͖ͳॴΛมߋʂ Saturday, June 21, 14
Thank you for using Heroku! Saturday, June 21, 14