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
ohr486
June 02, 2019
Technology
220
3
Share
demo-build-curd-app-with-serverless-elixir
ohr486
June 02, 2019
More Decks by ohr486
See All by ohr486
負荷試験Night#1 負荷試験2023年トレンド
ohr486
17
4.8k
Elixir/PhoenixによるWeb開発の現場から
ohr486
1
620
Hacking Phoenix Performance
ohr486
1
390
Plug & WAF
ohr486
2
540
elixirをプロダクションに導入する
ohr486
1
720
IEx maniacs
ohr486
4
640
Hack and Read Elixir
ohr486
2
800
Running App on AppRunner
ohr486
0
840
sponsor-talk-drecom-heisei-ruby-kaigi
ohr486
0
890
Other Decks in Technology
See All in Technology
Zephyr(RTOS)でOpenPLCを実装してみた
iotengineer22
0
180
スクラムを支える内部品質の話
iij_pr
0
170
Amazon Qはアマコネで頑張っています〜 Amazon Q in Connectについて〜
yama3133
1
170
20260326_AIDD事例紹介_ULSC.pdf
findy_eventslides
0
360
Physical AI on AWS リファレンスアーキテクチャ / Physical AI on AWS Reference Architecture
aws_shota
1
300
不確実性と戦いながら見積もりを作成するプロセス/mitsumori-process
hirodragon112
1
170
Oracle Cloud Infrastructure:2026年3月度サービス・アップデート
oracle4engineer
PRO
0
310
Network Firewall Proxyで 自前プロキシを消し去ることができるのか
gusandayo
0
160
「活動」は激変する。「ベース」は変わらない ~ 4つの軸で捉える_AI時代ソフトウェア開発マネジメント
sentokun
0
140
I ran an automated simulation of fake news spread using OpenClaw.
zzzzico
0
150
AWS DevOps Agent or Kiro の使いどころを考える_20260402
masakiokuda
0
140
Blue/Green Deployment を用いた PostgreSQL のメジャーバージョンアップ
kkato1
1
220
Featured
See All Featured
Documentation Writing (for coders)
carmenintech
77
5.3k
GraphQLとの向き合い方2022年版
quramy
50
14k
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
9
1.2k
Leadership Guide Workshop - DevTernity 2021
reverentgeek
1
260
AI: The stuff that nobody shows you
jnunemaker
PRO
4
500
Sam Torres - BigQuery for SEOs
techseoconnect
PRO
0
230
The Impact of AI in SEO - AI Overviews June 2024 Edition
aleyda
5
780
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
31
3.1k
Music & Morning Musume
bryan
47
7.1k
Mobile First: as difficult as doing things right
swwweet
225
10k
Between Models and Reality
mayunak
2
250
Bioeconomy Workshop: Dr. Julius Ecuru, Opportunities for a Bioeconomy in West Africa
akademiya2063
PRO
1
81
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貢献のチャンス!