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
ECS+S3でスクレイピングを試してみた
Search
sug1t0m0
July 05, 2019
Programming
0
980
ECS+S3でスクレイピングを試してみた
sug1t0m0
July 05, 2019
Tweet
Share
More Decks by sug1t0m0
See All by sug1t0m0
単純パーセプトロンで遊んでみたかった
sug1t0m0
0
690
20181130.pdf
sug1t0m0
0
670
渡る世間はナベばかり」でカルタ遊びをしてみての感想(大津の手法で「ナベ」カードを検出してみた)
sug1t0m0
0
830
Other Decks in Programming
See All in Programming
PHPで作るWebSocketサーバー ~リアクティブなアプリケーションを知るために~ / WebSocket Server in PHP - To know reactive applications
seike460
PRO
2
650
Androidアプリのモジュール分割における:x:commonを考える
okuzawats
1
190
SymfonyCon Vienna 2025: Twig, still relevant in 2025?
fabpot
3
1.2k
103 Early Hints
sugi_0000
1
260
htmxって知っていますか?次世代のHTML
hiro_ghap1
0
350
Cloudflare MCP ServerでClaude Desktop からWeb APIを構築
kutakutat
1
570
なまけものオバケたち -PHP 8.4 に入った新機能の紹介-
tanakahisateru
1
130
선언형 UI에서의 상태관리
l2hyunwoo
0
200
MCP with Cloudflare Workers
yusukebe
2
230
バグを見つけた?それAppleに直してもらおう!
uetyo
0
180
testcontainers のススメ
sgash708
1
130
命名をリントする
chiroruxx
1
450
Featured
See All Featured
The Invisible Side of Design
smashingmag
298
50k
What’s in a name? Adding method to the madness
productmarketing
PRO
22
3.2k
Fantastic passwords and where to find them - at NoRuKo
philnash
50
2.9k
Done Done
chrislema
182
16k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
127
18k
Fashionably flexible responsive web design (full day workshop)
malarkey
405
66k
Reflections from 52 weeks, 52 projects
jeffersonlam
347
20k
Building a Modern Day E-commerce SEO Strategy
aleyda
38
7k
Building Your Own Lightsaber
phodgson
103
6.1k
A Tale of Four Properties
chriscoyier
157
23k
Building Applications with DynamoDB
mza
91
6.1k
Making Projects Easy
brettharned
116
6k
Transcript
ECS+S3Ͱ εΫϨΠϐϯάΛࢼͯ͠Έͨ @sug1t0m0_agrict
ࣗݾհ ΤϯδχΞྺ - ϑϩϯτΤϯυ : 1 झຯ - ͓ञ αοΧʔ
ྉཧ ͓ञ ਿࢁ ஐ @sug1t0m0_agrict
ૣɺຊʹ
Ϟνϕʔγϣϯ - PythonͰαΠτΛεΫϨΠϐϯά͢ΔΞϓϦέʔγϣϯΛ࡞ - PythonϩʔΧϧڥΛԚછ͢Δ(Πϝʔδ)ͳͷͰ։ൃڥʹDockerΛબ - Ϋϩʔϥͱͯ͠ϔουϨεϒϥβΛར༻͔ͨͬͨ͠ͷͰɺίϯςφؒ௨৴ ͷ؆୯ԽͷͨΊʹαʔϏεΛ·ͱΊΔ͜ͱʹ ↓ -
2ίϯςφͰ1αʔϏε - ఆظ࣮ߦͱ͔ࢼͯ͠Έ͍ͨ ↓ ECS(ىಈλΠϓFargate)ʹσϓϩΠ (ͨ͠Β͍͍Μ͡Όͳ͍͔ͱࢥͬͨ)
ཧͷܗ
ݱ࣮ͷ
ͬͨ͜ͱ - εΫϨΠϐϯάΞϓϦέʔγϣϯΛDockernize - Ϋϥελ͔Β্هͷDockerίϯςφΛىಈ͢ΔλεΫΛ࣮ߦ - ϩάΛCloudWatchʹग़ྗ - εΫϨΠϐϯάͷग़ྗ݁ՌΛS3ʹอଘ -λεΫͷఆظ࣮ߦ
ݱঢ়
ϋϚͬͨͱ͜Ζ
λεΫ࣮ߦϩʔϧͷϙϦγʔΛΞλονͰ͖ͳ͍ - νϡʔτϦΞϧ: Amazon ECS CLI Λ༻ͯ͠ Fargate λεΫͷΫϥελʔΛ࡞͢ΔΛࢀߟʹ࡞ۀΛਐΊͯ ͍͕ͨҎԼͷίϚϯυ͕͏·࣮͘ߦ͞Εͳ͔ͬͨ
aws iam --region us-west-2 attach-role-policy - -role-name ecsTaskExecutionRole --policy-arn arn:aws:iam::aws:policy/service-role/AmazonECSTaskExecutionRolePolicy
ίϯςφʹڥมΛ͢ - Ϋϥελઃఆը໘͔ΒλεΫఆٛΛબ͠ ͯλεΫΛબ͢Δͱ͖ʹʮίϯςφͷ্ॻ ͖ʯ͔ΒڥมΛઃఆՄೳ
ϓϩηε͕ࢮΜͰκϯϏΈ͍ͨʹ ίϯςφ্ཱ͕͕ͪΔ - αʔϏεΛఆٛ͢Δ͜ͱʹΑΓɺΦʔτε έʔϧίϯςφ͕͚ͨ͜߹ʹ࠶ىಈ͞Ε Δతͳ͜ͱ͕ॻ͍͕ͯ͋ͬͨ͜Ε͕ݪҼ?
ఆظ࣮ߦՄೳͩͬͨ - λεΫͷఆظ࣮ߦΫϥελͷઃఆը໘͔ ΒઃఆՄೳ - cronه๏༻Մೳ
Ռ
·ͱΊ
·ͱΊ - S3ͷΞΫηεΩʔΛڥมͱͯ͠ίϯςφʹ ͕ͨ͠, ͬͱ͍͍ํ๏͕͋Δͣ - 1λεΫͰىಈ͢ΔίϯςφΛ૿ͯ͠ίϯς φؒ௨৴Λࢼͯ͠Έ͍ͨ - ecs-cli
up ίϚϯυͰαϒωοτ͕2ͭఆٛ͞Ε ͨVPC͕ੜ͞ΕΔͷԿނͳͷ͔? (azʹґଘ͢ΔΒ͍͠ɺ࣭ٙԠͷ࣌ؒʹղܾ)