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
月額10円から作るServerless Website〜Azure編〜/serverlessf...
Search
Kunihiro Morita
August 25, 2017
Technology
8
17k
月額10円から作るServerless Website〜Azure編〜/serverlessfukuoka-20170825
2017/8/25 Serverless Meetup Fukuoka #1 の資料です。
https://serverless.connpass.com/event/62473/
Kunihiro Morita
August 25, 2017
Tweet
Share
More Decks by Kunihiro Morita
See All by Kunihiro Morita
絵で覚える AWS 全 (?) サービス入門 〜 できるAWSカルタ 〜/jawsug-20191019
morita92hiro
1
2.3k
決戦用MSセンチネル/alterbooth-20190606
morita92hiro
1
250
勝手にAlibaba Cloud White Beltシリーズ Elastic Compute Service(ECS)/alieaters-20190301
morita92hiro
0
400
夏休みで差がつく!Ansible/ansiblejp-20180803
morita92hiro
2
2.6k
希望のRancher〜コンテナをアウフヘーベン〜/ranchermeetup-20171006
morita92hiro
0
290
いまからDockerで始めるGitLab CE/gitlabjp-20170919
morita92hiro
1
1.4k
コンテナ運用いきのこるには/ranchermeetup-20170807
morita92hiro
1
570
AWS Summit Tokyoをお探しですか?/jawsug-20170713
morita92hiro
0
180
ブラウザだけでインフラ操作?〜これさえあれば、何もいらない。〜/fukuazu-20170622
morita92hiro
1
910
Other Decks in Technology
See All in Technology
AWS re:Invent 2024 recap in 20min / JAWSUG 千葉 2025.1.14
shimy
1
100
生成AI × 旅行 LLMを活用した旅行プラン生成・チャットボット
kominet_ava
0
160
データ基盤におけるIaCの重要性とその運用
mtpooh
4
530
メンバーがオーナーシップを発揮しやすいチームづくり
ham0215
2
140
0→1事業こそPMは営業すべし / pmconf #落選お披露目 / PM should do sales in zero to one
roki_n_
PRO
1
1.5k
Oracle Exadata Database Service(Dedicated Infrastructure):サービス概要のご紹介
oracle4engineer
PRO
0
12k
Unsafe.BitCast のすゝめ。
nenonaninu
0
200
実践! ソフトウェアエンジニアリングの価値の計測 ── Effort、Output、Outcome、Impact
nomuson
0
2.1k
あなたの人生も変わるかも?AWS認定2つで始まったウソみたいな話
iwamot
3
860
20250116_自部署内でAmazon Nova体験会をやってみた話
riz3f7
1
100
FODにおけるホーム画面編成のレコメンド
watarukudo
PRO
2
280
Amazon Q Developerで.NET Frameworkプロジェクトをモダナイズしてみた
kenichirokimura
1
200
Featured
See All Featured
Code Review Best Practice
trishagee
65
17k
Designing for humans not robots
tammielis
250
25k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
27
1.5k
Bash Introduction
62gerente
610
210k
VelocityConf: Rendering Performance Case Studies
addyosmani
327
24k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
330
21k
Building Better People: How to give real-time feedback that sticks.
wjessup
366
19k
Site-Speed That Sticks
csswizardry
3
270
Into the Great Unknown - MozCon
thekraken
34
1.6k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
3
360
Fantastic passwords and where to find them - at NoRuKo
philnash
50
2.9k
How to Ace a Technical Interview
jacobian
276
23k
Transcript
ֹ݄10ԁ͔Β࡞Δ Serverless Website ʙAzureฤʙ #serverlessfukuoka 2017/8/25 Serverless Meetup Fukuoka #1
1
AWSฤ(2016/3/21)1 1 https://speakerdeck.com/morita92hiro/yue-e-10yuan-karazuo-ruserverless-website 2017/8/25 Serverless Meetup Fukuoka #1 2
ా༟ גࣜձࣾΦϧλʔϒʔε ιϦϡʔγϣϯΞʔΩςΫτ @morita92hiro http://hawaku.hateblo.jp 2017/8/25 Serverless Meetup Fukuoka #1
3
ʮ1܅ɺLPαΠτ࡞ͬ ͯɻCMS͍Βͳ͍ɻʯ 2017/8/25 Serverless Meetup Fukuoka #1 4
>>1ʮWeb Appsͷग़൪ʂʯ 2017/8/25 Serverless Meetup Fukuoka #1 5
Web Apps • WebαΠτɺWebΞϓϦͷϗετʹ࠷దԽͨ͠αʔϏε • ߴՄ༻ੑɺCI/CD • αΠτ٧Ί์ 2017/8/25 Serverless
Meetup Fukuoka #1 6
ʮ1܅ɺ͓͍߹Θͤϖʔδ࡞ͬͯʯ >>1ʮ͋ͬɺ͍ʯ 2017/8/25 Serverless Meetup Fukuoka #1 7
Web Apps • ASP.NETɺNode.jsɺJavaɺPHPɺPython • on Linux(preview) • Node.jsɺPHPɺ.NET CoreɺRubyɺDocker
2017/8/25 Serverless Meetup Fukuoka #1 8
ʮ1܅ɺHTTPSԽΑΖʯ 2017/8/25 Serverless Meetup Fukuoka #1 9
HTTPSԽ • SSLΛߪೖͯ͠ಋೖ • ֦ுػೳͱͯ͠Let's Encrypt͕͑Δ 2017/8/25 Serverless Meetup Fukuoka
#1 10
>>1ʮWebαΠτʹ Web App࠷ద͊… ( ˘ω˘)ţźōʯ 2017/8/25 Serverless Meetup Fukuoka #1
11
ʮ1܅ɺྉ͕ۚɻ10ԁͲ ͍ͬͨ͜ʁʯ 2017/8/25 Serverless Meetup Fukuoka #1 12
>>1ʮWeb App Freeϓ ϥϯʹมߋʂʯ 2017/8/25 Serverless Meetup Fukuoka #1 13
>>1ʮFreeϓϥϯΧελϜυϝΠϯ͑ͳ͍ɾɾɾʯ 2017/8/25 Serverless Meetup Fukuoka #1 14
>>1ʮCDNೖΕͯΧελ ϜυϝΠϯׂΓͯʂʯ 2017/8/25 Serverless Meetup Fukuoka #1 15
Azure CDN • ίϯςϯπσϦόϦʔαʔϏε • GzipѹॖػೳͰ͞Βʹߴɺసૹίετݮʂ 2017/8/25 Serverless Meetup Fukuoka
#1 16
>>1ʮ͋ɺSSLূ໌ॻɾɾɾʯ 2017/8/25 Serverless Meetup Fukuoka #1 17
>>1ʮങͬͯΒ͓͏ʯ • Let's Encryptͷূ໌ॻAzure CDNͰ(ͨͿΜ)͑Δ • Let's Encryptͷূ໌ॻ3ϲ݄ظݶ • ࣗಈߋ৽ͷΈΛ࡞ΔΑΓങ͏΄͏͕͍҆ʢʼߪೖʣ
• DVূ໌ॻͳΒ1,000ԁ/લޙ͔ΒߪೖՄೳ • AWS Certificate Manager(ACM)͕Azureʹɾɾɾ|дƅ)ŧŽŕ 2017/8/25 Serverless Meetup Fukuoka #1 18
ొஃޙهʢగਖ਼ʣ Azure CDNʹHTTPS͕؆୯ʹ͑Δػೳ͕͋Γ·ͨ͠ɻ • Azure CDN ΧελϜ υϝΠϯͷ HTTPS ͷ༗ޮԽ
https://docs.microsoft.com/ja-jp/azure/cdn/cdn-custom-ssl 2017/8/25 Serverless Meetup Fukuoka #1 19
தؒ·ͱΊ • 10ԁ/݄͙Β͍ʁ+SSLূ໌ॻ(Web Appແྉϓϥϯ) • 1,000ԁ/݄͙Β͍ʁ(Web App༗ྉϓϥϯ)ɻαΠτ٧Ί์ 2017/8/25 Serverless Meetup
Fukuoka #1 20
ʮ1܅ɺ͜ΕαʔόʔϨεͳͷʁʯ >>1ʮPaaSͰ͢ʯ 2017/8/25 Serverless Meetup Fukuoka #1 21
αʔόʔϨεͱ2 ऍᷟʹઆ๏Ͱ͕͢… αʔόʔϨεɺαʔόʔ͕ͳ͍͜ͱΛࣔ͢Θ͚Ͱͳ͘ɺ։ ൃऀ͕αʔόʔʹ͍ͭͯ৺͢Δඞཁ͕ͳ͍͜ͱΛ͍ࣔͯ͠Δ ͚ͩͰ͢ɻ ैདྷͷΞϓϦέʔγϣϯ։ൃͷେ͖ͳ෦ɺΞϓ ϦέʔγϣϯͷཁٻΛຬͨͨ͢ΊͷιϦϡʔγϣϯͷεέʔϦ ϯάɺϗεςΟϯάɺࢹʹؔ͢Δ࣭ʹ͑Δͱ͜Ζʹ͋Γ· 2 https://docs.microsoft.com/ja-jp/azure/logic-apps/logic-apps-serverless-overview
2017/8/25 Serverless Meetup Fukuoka #1 22
>>1ʮมߋʂʯ 2017/8/25 Serverless Meetup Fukuoka #1 23
>>1ʮBLOB͏Αʂʯ 2017/8/25 Serverless Meetup Fukuoka #1 24
Azure Blob Storage • ΦϒδΣΫτετϨʔδ • ؆қ੩తαΠτ • ੑ(LRS/GRS/RA-GRS) 2017/8/25
Serverless Meetup Fukuoka #1 25
>>1ʮindex.htmlະରԠɾɾɾʯ http://example.com/ͷΞΫηεͰindex.htmlΛදࣔͯ͘͠Εͳ͍ 2017/8/25 Serverless Meetup Fukuoka #1 26
>>1ʮCDNೖΕΔʂʯ 2017/8/25 Serverless Meetup Fukuoka #1 27
Azure CDN Rules Engine3 • HTTPཁٻͷॲཧํ๏ΛΧελϚΠζՄೳ • ReWrite RuleͰindex.htmlରԠ5 5
https://stackoverflow.com/questions/37368829/azure-cdn-rules-engine-to-rewrite-default-document-and-remove-html- extension 3 https://docs.microsoft.com/ja-jp/azure/cdn/cdn-rules-engine 2017/8/25 Serverless Meetup Fukuoka #1 28
>>1ʮ͋ͬɺ͓͍߹Θ ͤϖʔδ!ʯ 2017/8/25 Serverless Meetup Fukuoka #1 29
>>ʮJSͰBLOBʹPOST͓͍ͯ͠߹ Θͤσʔλஔ͍ͯɺʯ 2017/8/25 Serverless Meetup Fukuoka #1 30
>>1ʮJS͕BLOBͷॻ͖ࠐΈݖݶඞ ཁ͠ɺJSʹೝূใΛॻ͖ࠐΉͷ ɾɾɾʯ 2017/8/25 Serverless Meetup Fukuoka #1 31
>>1ʮ͍ࣺͯͳೝূใΛऔಘͰ͖ Εɾɾɾʯ 2017/8/25 Serverless Meetup Fukuoka #1 32
>>1ʮSASͱAzure Functionʂʯ 2017/8/25 Serverless Meetup Fukuoka #1 33
Shared Access Signatures(SAS) • ະೝূήετʹॻ͖ࠐΈݖݶ • Ұ࣌తͳೝূใΛൃߦ • SAS TokenAzure
Functionܦ༝Ͱऔಘ 2017/8/25 Serverless Meetup Fukuoka #1 34
Azure Function • ΠϕϯττϦΨʔͰىಈ • C#ɺF#ɺNode.jsɺPythonɺPHPɺBatchɺBash͕͑Δ • ͓͍߹Θ͕ͤདྷͨΒඞཁͳ௨ઌ 2017/8/25 Serverless
Meetup Fukuoka #1 35
ิ • ͓͍߹Θͤσʔλஔ͖ʹCORSઃఆ • POST߈ܸ͞Εͨ͘ͳ͍ͷͰ͔ͬ͠Γ੍ݶ! 2017/8/25 Serverless Meetup Fukuoka #1
36
>>1ʮͰ௨ʹඞཁͳೝূใΛ FunctionʹຒΊࠐΈͨ͘ͳ͍ɾɾɾʯ 2017/8/25 Serverless Meetup Fukuoka #1 37
>>1ʮThe Twelve-Factor Appʯ4 4 https://12factor.net/ja/ 2017/8/25 Serverless Meetup Fukuoka #1
38
3ষ ઃఆ4 ઃఆΛڥมʹ֨ೲ͢Δ ΞϓϦέʔγϣϯ࣌ʹઃఆΛఆͱͯ͠ίʔυʹ֨ೲ͢ Δɻ͜ΕTwelve-Factorʹҧ͍ͯ͠ΔɻTwelve-Factor ઃఆ Λίʔυ͔Βݫີʹ͢Δ͜ͱ Λཁٻ͢ΔɻઃఆσϓϩΠ ͝ͱʹେ͖͘ҟͳΔ͕ɺίʔυͦ͏Ͱͳ͍ɻ 4
https://12factor.net/ja/ 2017/8/25 Serverless Meetup Fukuoka #1 39
>>1ʮAzure FunctionͷڥมΛ͏Αʯ 2017/8/25 Serverless Meetup Fukuoka #1 40
தؒ·ͱΊ • 10ԁ/݄͙Β͍ʁʴSSLূ໌ॻ 2017/8/25 Serverless Meetup Fukuoka #1 41
ʮ1܅ɺ࣌ػցֶशʯ 2017/8/25 Serverless Meetup Fukuoka #1 42
>>1ʮɾɾɾʯ 2017/8/25 Serverless Meetup Fukuoka #1 43
>>1ʮCognitive Services!ʯ 2017/8/25 Serverless Meetup Fukuoka #1 44
Cognitive Services • REST APIͷαʔϏε܈ • ײݕग़ɺࢹ֮ೝࣝɺԻೝࣝɺݴޠཧղͳͲࢁ • ػցֶशͷ͕ࣝͳͯ͑͘Δ 2017/8/25
Serverless Meetup Fukuoka #1 45
Մೳੑ∞ • ࠓճͷέʔεͩͱ͓͍߹Θͤ༰Ληϯνϝϯτੳͱ͔ • ը૾ΛPOSTग़དྷΔΑ͏ʹͯ͠ըղੳͱ͔ 2017/8/25 Serverless Meetup Fukuoka #1
46
ͪͳΈʹ 2017/8/25 Serverless Meetup Fukuoka #1 47
Azure FunctionʹPOSTύλʔϯ • Funtion࣮ߦ࣌ؒ57 • ͍λεΫQueueΛڬΜͰϐλίϥ8 8 https://buildazure.com/2017/08/15/scaling-azure-functions-with-durable-functions/ 7 https://buildazure.com/2017/08/17/azure-functions-extend-execution-timeout-past-5-minutes/
2017/8/25 Serverless Meetup Fukuoka #1 48
தؒ·ͱΊ • SAS+Azure Funtion(10ԁ/݄͙Β͍?+SSLূ໌ॻ) • Azure FunctionPOST(10ԁ/݄͙Β͍?+SSLূ໌ॻ) 2017/8/25 Serverless Meetup
Fukuoka #1 49
>>1ʮͦ͏ͩʂʯ 2017/8/25 Serverless Meetup Fukuoka #1 50
>>1ʮαʔόʔϨείʔυϨεʹ͠Α͏ʯ 2017/8/25 Serverless Meetup Fukuoka #1 51
>>1ʮLogic Appsʂʯ 2017/8/25 Serverless Meetup Fukuoka #1 52
Logic Apps • IFTTTmyThingsɺMS FlowΈ͍ͨͳͭ • ը໘ϙνϙνͰઃఆɻInfrastructure as CodeͰཧՄೳ •
ߴͳ͜ͱΛ͍ͨ͠ͱ͖Azure FunctionͱΈ߹ΘͤΔ 2017/8/25 Serverless Meetup Fukuoka #1 53
>>1ʮLogic AppsͷWebhookʹ CORSઃఆͰ͖ͳ͍ɾɾɾʯ 2017/8/25 Serverless Meetup Fukuoka #1 54
>>1ʮAzure Function ProxyڬΉʂʯ 2017/8/25 Serverless Meetup Fukuoka #1 55
Azure Function Proxy • ΤϯυϙΠϯτڞ௨Խ • API ManagementΑΓϥΠτʹ͑Δ(Β͍͠) • CORSઃఆͰ͖Δ(ࠓճ͜Ε͕త)
2017/8/25 Serverless Meetup Fukuoka #1 56
ิࢿྉ FlowɺLogic AppsɺFunctionsɺWebJobsͷൺֱ9 de:code 2017ͰAzure FunctionsͱLogic AppsͷΛ͖ͯͨ͠10 Azure App ServiceɺVirtual
MachinesɺService FabricɺCloud Servicesͷൺֱ11 11 https://docs.microsoft.com/ja-jp/azure/app-service-web/choose-web-site-cloud-service-vm 10 http://yoshidashingo.hatenablog.com/entry/2017/06/17/112504 9 https://docs.microsoft.com/ja-jp/azure/azure-functions/functions-compare-logic-apps-ms-flow-webjobs 2017/8/25 Serverless Meetup Fukuoka #1 57
>>1ʮ৽αʔϏεʂʯ 2017/8/25 Serverless Meetup Fukuoka #1 58
Event Grid6 • 8/17ੜ • preview • αʔόʔϨεΞϓϦέγϣϯ։ൃ • OpsࣗಈԽ
ࠓޙAzureͷαʔόϨεΞʔΩςΫνϟ ͷத৺ʹͳ͍ͬͯ͘ʁ 6 https://docs.microsoft.com/en-us/azure/event-grid/overview 2017/8/25 Serverless Meetup Fukuoka #1 59
Azure Container Instance • ίϯςφͷϑϧϚωʔδυαʔϏε • FaaSͷಈ࡞ڥͱͯ͠ • kubernetesͷԾϊʔυͱͯ͠ར༻Մ •
preview 2017/8/25 Serverless Meetup Fukuoka #1 60
·ͱΊ • Web Appsύλʔϯ(ิ:CognitiveՃͰར༻Մೳ) • Blobύλʔϯ 2017/8/25 Serverless Meetup Fukuoka
#1 61
ServerlessPaaS࠷దʹ࣮ݱͰ͖ Δग़དྷΔͳΒͲͪΒͰ(ɾ˲ɾ)ŘŘ!! 2017/8/25 Serverless Meetup Fukuoka #1 62
σϞ Logic Apps+Cognitive Services 2017/8/25 Serverless Meetup Fukuoka #1 63
͓ΘΓ 2017/8/25 Serverless Meetup Fukuoka #1 64