Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
AWS App Runnerがそろそろ本番環境でも使い物になりそう
Search
n1215
December 20, 2022
Programming
15k
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
AWS App Runnerがそろそろ本番環境でも使い物になりそう
LTで使ったAWS App Runnerのスライドです
n1215
December 20, 2022
More Decks by n1215
See All by n1215
面倒なのは嫌なのでコンテナのマネージドサービスの極振りしたいと思います。
n1215
8
3.7k
テスト環境のインフラ・運用コストを下げたい話〜全部入りEC2を超えていけ
n1215
4
2.2k
RoadRunnerの世界 〜 Yet Another Alt PHP-FPM
n1215
2
6.1k
ブラウザから始めるgRPC 〜 gRPC-WebにPHPを添えて
n1215
1
6.7k
PHP8時代のWebアプリケーションフレームワークの話をしよう
n1215
7
7.5k
PHPとEventSauceで始めるイベントソーシングアプリケーション
n1215
9
4.6k
形から入ったドメイン駆動設計によるゲーム開発の光と闇
n1215
13
8.4k
PHPでもgRPCサーバを立てたいだけの人生だった
n1215
7
10k
PSR-15 Request Handlerから理解するMiddlewareの仕組み
n1215
3
2.8k
Other Decks in Programming
See All in Programming
デプロイ直後のレイテンシスパイクを調べたら、 Railsの仕様にたどり着いた
nhsykym
0
110
tsc.rip を支える技術 / Kyoto.なんか #8
susisu
0
4.4k
信頼性の目標を誰も求めてない
shubox
0
500
マイコン向けの軽量Ruby「PicoRuby」で各種デバイスを制御するネイティブアプリの実現手法
bash0c7
0
160
go-spidermonkeyでAIエージェントのCode Modeを実装する
syumai
3
1.5k
thread_parallel_with_free-threaded_Python_and_NumPy.pdf
riku_sakamoto
0
160
Swift愛好会と私(ウホーイ) / Swift Fan Club and Uhooi
uhooi
0
150
MIZARU@SPAJAM2026 第二回予選
1901drama
0
110
Can LLMs Replicate 4 Years of Compose Migration? Exploring the boundaries of automation with 279 XML files from a real product
makun
0
130
What We Talk About When We Talk About XP
m_seki
2
420
iOS開発×AI駆動開発 〜最近使って便利だったスキルの話〜
nogu66
0
140
typoなんかねぇよ
raspython3
0
680
Featured
See All Featured
Designing Powerful Visuals for Engaging Learning
tmiket
1
530
Are puppies a ranking factor?
jonoalderson
2
3.9k
VelocityConf: Rendering Performance Case Studies
addyosmani
331
25k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
230
23k
The SEO Collaboration Effect
kristinabergwall1
1
550
Side Projects
sachag
455
43k
How to Think Like a Performance Engineer
csswizardry
28
2.8k
Why Mistakes Are the Best Teachers: Turning Failure into a Pathway for Growth
auna
0
260
Claude Code どこまでも/ Claude Code Everywhere
nwiizo
67
58k
Design of three-dimensional binary manipulators for pick-and-place task avoiding obstacles (IECON2024)
konakalab
0
580
For a Future-Friendly Web
brad_frost
183
10k
Balancing Empowerment & Direction
lara
6
1.3k
Transcript
AWS App Runnerがそろそろ本番環境でも使い物 になりそう 2022年12月20日 (火) 株式会社Nextat 中榮健二 1
1. AWS App Runner 概要 2
AWS App Runner概要 https://aws.amazon.com/jp/apprunner/ 2021年5月にリリース コンテナ化されたウェブアプリケーションのフルマネージドサービス GitHubのリポジトリからのソースコードベースのデプロイとECRからのコンテナ ベースのデプロイに対応 バックエンドはFargate(Firecracker VM)
3
構成 参考:https://dev.classmethod.jp/articles/report-con406-reinvent2022/ 4
ECSとの違い デプロイパイプラインを自前で用意する必要がない ロードバランサーも組込みなのでALBなどを別途使う必要がない 1つのサービスに対し複数のコンテナを組み合わせられない オートスケールの設定項目 最小/最大インスタンス数、1コンテナあたりの同時リクエスト数の3項目 その他設定項目もECSと比べると細やかさはないがかなり楽 ECSタスクに相当するジョブの機能はない ECS Execに相当する機能はない
Arm(Graviton)、Windowsコンテナ未対応 5
2. 今年の注目のアップデート3つ 6
2022/02/08 カスタマーVPCへの接続が可能に https://docs.aws.amazon.com/apprunner/latest/relnotes/release-2022- 02-08-vpc.html VPCコネクタ対応 DynamoDBなどグローバルなリソースだけでなく、RDSなどVPC内のリソースが 使えるようになった 7
8
2022/10/28 マネージドランタイムの言語対応追加 https://aws.amazon.com/jp/about-aws/whats-new/2022/10/aws-app- runner-support-php-go-dot-net-ruby-managed-runtimes/ GitHubからの自動デプロイで利用される JavaとNode.jsのみだったところにPHP、Go、.NET、Rubyが追加 9
2022/10/31 プライベートアクセスが可能に https://aws.amazon.com/jp/about-aws/whats-new/2022/11/aws-app- runner-supports-privately-accessible-services-amazon-vpc/ インターネット経由の公開アクセスに限定されていたが、プライベートサービスを 選択するとVPC内からのアクセスに限定できるようになった VPCエンドポイント経由のアクセス CloudFront + WAFによる防御時の迂回路がなくなった
VPC内からアクセスするマイクロサービスをApp Runnerで作成することも可能 になった 10
Before 11
After 12
3. 料金など 13
料金について CloudFront + WAF + VPCエンドポイント(2AZ) + App Runner vCPU
1、メモリ2GB ずっと待機状態とすると5500円くらい(リクエスト時間に応じて料金増) CloudFront + WAF + ALB + ECS/Fargate vCPU0.5、メモリ1GB 6,500円くらい DBは未考慮、デプロイ・ビルドの料金(誤差)は別 プライベート構成にするとENIが高い(AZを減らせばもうちょい減る)がALBと トントンくらいか アクセス数の少ない社内アプリくらいであればECSより安そうな感じ 趣味で使うには高いか 14
改善されてほしい点 ゼロスケール https://github.com/aws/apprunner-roadmap/issues/9 ENIからFargateにアクセスする構成だとECS on Fargateと大差ない コールドスタート30秒くらいになりそうなのでしばらく無理そう Secrets Managerからの環境変数の読込 https://github.com/aws/apprunner-
roadmap/issues/6 最低スペック変更 https://github.com/aws/apprunner-roadmap/issues/25 vCPU 1 + メモリ2GBが最低スペックなので Arm対応 https://github.com/aws/apprunner-roadmap/issues/98 サイドカー対応(無理そう) https://github.com/aws/apprunner- roadmap/issues/71 PHPのマネージドランタイムでビルトインウェブサーバーを使わせるのをやめろ https://github.com/aws/apprunner-roadmap/issues/157 15
まとめ VPCコネクタによりRDSなどVPC内リソースへの接続に対応 プライベートエンドポイントによりWAFでの完全防御やマイクロサービスに対応 マネージドランタイムがGoなどにも対応 ECS/Fargateの代替として十分アリ AWS縛りがなければ Fly.io、Render、RailwayのようなPaaSかGCPの Cloud Runのほうが良さそう スケーリングや料金面はまだまだAWS
Lambdaが強い エンドポイントの多いHTTP APIを全部Lambdaにする構成は正直アンチパタ ーンだと思うのでコンテナ系のサービスには頑張ってほしい 16
ご清聴ありがとうございました 17