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
demo-build-curd-app-with-serverless-elixir
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
ohr486
June 02, 2019
Technology
3
220
demo-build-curd-app-with-serverless-elixir
ohr486
June 02, 2019
Tweet
Share
More Decks by ohr486
See All by ohr486
負荷試験Night#1 負荷試験2023年トレンド
ohr486
17
4.8k
Elixir/PhoenixによるWeb開発の現場から
ohr486
1
610
Hacking Phoenix Performance
ohr486
1
380
Plug & WAF
ohr486
2
530
elixirをプロダクションに導入する
ohr486
1
700
IEx maniacs
ohr486
4
630
Hack and Read Elixir
ohr486
2
780
Running App on AppRunner
ohr486
0
830
sponsor-talk-drecom-heisei-ruby-kaigi
ohr486
0
870
Other Decks in Technology
See All in Technology
コスト削減から「セキュリティと利便性」を担うプラットフォームへ
sansantech
PRO
3
1.5k
フルカイテン株式会社 エンジニア向け採用資料
fullkaiten
0
10k
Sansan Engineering Unit 紹介資料
sansan33
PRO
1
3.9k
マーケットプレイス版Oracle WebCenter Content For OCI
oracle4engineer
PRO
5
1.6k
Digitization部 紹介資料
sansan33
PRO
1
6.8k
Amazon S3 Vectorsを使って資格勉強用AIエージェントを構築してみた
usanchuu
3
450
OWASP Top 10:2025 リリースと 少しの日本語化にまつわる裏話
okdt
PRO
3
820
Bill One急成長の舞台裏 開発組織が直面した失敗と教訓
sansantech
PRO
2
380
広告の効果検証を題材にした因果推論の精度検証について
zozotech
PRO
0
190
SREが向き合う大規模リアーキテクチャ 〜信頼性とアジリティの両立〜
zepprix
0
460
M&A 後の統合をどう進めるか ─ ナレッジワーク × Poetics が実践した組織とシステムの融合
kworkdev
PRO
1
470
CDKで始めるTypeScript開発のススメ
tsukuboshi
1
470
Featured
See All Featured
Designing for Performance
lara
610
70k
Navigating Algorithm Shifts & AI Overviews - #SMXNext
aleyda
0
1.1k
Dominate Local Search Results - an insider guide to GBP, reviews, and Local SEO
greggifford
PRO
0
78
Marketing Yourself as an Engineer | Alaka | Gurzu
gurzu
0
130
Efficient Content Optimization with Google Search Console & Apps Script
katarinadahlin
PRO
1
320
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
194
17k
The Cost Of JavaScript in 2023
addyosmani
55
9.5k
AI: The stuff that nobody shows you
jnunemaker
PRO
2
260
16th Malabo Montpellier Forum Presentation
akademiya2063
PRO
0
51
Marketing to machines
jonoalderson
1
4.6k
エンジニアに許された特別な時間の終わり
watany
106
230k
From Legacy to Launchpad: Building Startup-Ready Communities
dugsong
0
140
Transcript
DEMO build crud app with serverless elixir おーはら@tokyo.ex
agenda • about me • how to run • demo
• まとめ
about me • Tsunenori Ohara/おーはら ◦ Twitter: @ohrdev ◦ Github:
ohr486
how to run repo: https://github.com/ohr486/serverless_elixir_demo 利用ライブラリ: - erllambda - mix_erllambda
以下のようなアプリを作成します - CR(U)D操作のできるAPI - 環境はAWS、Lambda、ApiGatewayを利用 - DBはDynamoDBを利用
step0 • release buildの為のdocker imageのbuild ◦ https://github.com/alertlogic/erllambda_docker • build ◦
mix deps.get ◦ docker run -it --rm -v `pwd`:/buildroot -w /buildroot -e MIX_ENV=prod erllambda:21-elixir mix erllambda.rellease
step1 • cloudformationの為のS3 bucketを作成
step2 • パッケージング ◦ aws cloudformation package --template-file etc/template.yaml --output-template-file
packaged.yaml --s3-bucket japanex-demo
step3 • deploy ◦ aws cloudformation deploy --capabilities CAPABILITY_IAM --template-file
packaged.yaml --stack-name japanex-demo
step4 • deployスタックを確認 ◦ aws cloudformation describe-stacks --stack-name japanex-demo --query
'Stacks[].Outputs' ◦ 作成したendpointを確認 • API ENDPOINTの設定 ◦ export APIENDP=xxxxxxx
step5 • アイテムの作成 (CRUD) ◦ curl -X POST "$APIENDP?id=foo2&bar=quz2"
step6 • アイテムリスト取得 ◦ curl $APIENDP
step7 • アイテム削除 ◦ curl -X DELETE "$APIENDP?id=foo2"
step8 • アプリ削除 ◦ aws cloudformation delete-stack --stack-name japanex-demo
まとめ • 簡単なCR(U)Dアプリをserverlessで作成するデモを行いました • デモの通り、まだまだオペレーションが煩雑です ◦ このあたりをいい具合にラップしてくれるツール /FW等は現状まだありません ◦ oss貢献のチャンス!