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
Supabase CLIのある開発日常
Search
TakashiAsanuma
August 22, 2024
Programming
360
3
Share
Supabase CLIのある開発日常
TakashiAsanuma
August 22, 2024
More Decks by TakashiAsanuma
See All by TakashiAsanuma
Skills間の連携も関数のようにしたら快適だった話
takashiasanuma
1
1.5k
DCC2P_IDCFクラウドコンテナ商用サービス事例紹介
takashiasanuma
0
99
SUSE RancherとKubernetes環境へのWAF対応
takashiasanuma
0
210
RubyによるPub/Sub messaging - パブリッククラウドのバックエンドシステム事例 /Public Cloud backend system
takashiasanuma
0
160
RubyでPub/Sub messaging-Multi Process-Daemonizes-Application
takashiasanuma
1
12k
Scalable Applications with Pub/Sub Messaging
takashiasanuma
0
130
Pub/Subメッセージングのテスト(LT版)
takashiasanuma
0
110
IDCクラウドのバックエンド
takashiasanuma
0
150
CMやるよって言われてからのインフラチューニング
takashiasanuma
0
240
Other Decks in Programming
See All in Programming
Modding RubyKaigi for Myself
yui_knk
0
830
AI駆動開発で崩れていくコードベースを立て直す
kyoko_nr_nr
1
400
3Dシーンの圧縮
fadis
1
540
tsserverとは何だったのか、これからどうなるのか
nowaki28
1
430
開発体験を左右するライブラリの API 設計 - GraphQL スキーマ構築ライブラリから考える #tskaigi
izumin5210
2
1.4k
Transactional Change Stream Processing With Debezium and Apache Flink
gunnarmorling
1
140
Java × distroless で 軽量なコンテナイメージを / Java on Distroless
contour_gara
0
430
柔軟なPDFレイアウトエディタを支える型システム設計 — Discriminated UnionとConditional Typeの実践
minako__ph
4
1.2k
プラグインで拡張される Context をtype-safe にする難しさと設計判断
kazupon
2
490
These Five Tricks Can Make Your Apps Greener, Cheaper, & Nicer
hollycummins
0
250
SPMマルチモジュールで テストカバレッジを取得する技法
yosshi4486
0
130
サーバーレスで作る、動画データ管理基盤
oyasumipants
0
320
Featured
See All Featured
Code Review Best Practice
trishagee
74
20k
Stewardship and Sustainability of Urban and Community Forests
pwiseman
0
220
The Impact of AI in SEO - AI Overviews June 2024 Edition
aleyda
5
1.1k
Groundhog Day: Seeking Process in Gaming for Health
codingconduct
0
190
Breaking role norms: Why Content Design is so much more than writing copy - Taylor Woolridge
uxyall
0
300
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3.5k
Data-driven link building: lessons from a $708K investment (BrightonSEO talk)
szymonslowik
1
1.1k
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
16
2k
How to Get Subject Matter Experts Bought In and Actively Contributing to SEO & PR Initiatives.
livdayseo
0
130
The Organizational Zoo: Understanding Human Behavior Agility Through Metaphoric Constructive Conversations (based on the works of Arthur Shelley, Ph.D)
kimpetersen
PRO
0
340
Hiding What from Whom? A Critical Review of the History of Programming languages for Music
tomoyanonymous
2
830
How to Grow Your eCommerce with AI & Automation
katarinadahlin
PRO
1
190
Transcript
Supabase CLIのある開発日常 株式会社Berry 浅沼 敬 2024/8/22 Supabase Tokyo Meetup
会社紹介:株式会社Berry 赤ちゃん向けの頭蓋形状矯正ヘルメットを提供する医療機器メーカーです 株式会社Berry https://www.berryinc.co.jp/
BerryはSupabaseを採用して3年 Findy Toolsへ導入事例を寄稿したり、テックブログで紹介したりしています Findy Tools Supabase導入事例 https://findy-tools.io/products/supabase/32/117 Berry テックブログ Supabaseでアプリをリリースする前に確認すること
https://zenn.dev/berry_blog/articles/cfce64da076878
背景・モチベーション Supabaseを使うなら、Supabase CLIも使わないともったいない! Berry入社時は、リモートのSupabaseを共有して開発していた ↓ Supabase CLIを利用:ローカル開発・CIの開発体験が爆上がり
Supabase CLI:よく使うコマンド > yarn supabase gen types typescript --local も必須で使う
開発の流れ ローカル SupabaseUI Supabase CLI テーブル 追加・編集 db diff テストデータ
db dump VSCode 実装・テスト Github Pull Request Github Actions CI db reset
デモ https://youtu.be/xYMo_KTpaHU?si=tyH-Qokoh9OfCk OY
ローカル & Github Actions の容易さ Supabase CLIの旨味はGithub Actions - Migration
& seed.sqlでローカルも Github Actions上も同じ状態にできる - 公式のActionsが用意されているので、 簡単にCIを始めることができる - 環境違いに困ることがない
環境による認知負荷を生みにくい ⇒ 開発体験向上 ローカル&Github Actionsとリモートは、すべて同じ環境になる = 環境によって覚えることを変えなくて良い! Supabase CLI migration
seed Github Actions Develop ment Supabase migration Staging Production
まとめ: 認知負荷と学習コストの軽減は、クラウドの本質的な恩恵でありがたい ・学習コストも低い Docker File, Docker Compose, Kube Manifest, TeraForm…
で、開発環境を構築してきた中で、もっとも簡単で快適
おまけ:Authを通してRLSをテストする Berry テックブログ VitestをつかってSupabaseのRow Level Security(RLS)の Policyをテストする https://zenn.dev/berry_blog/articles/03beda8c668127
Wantedly:株式会社Berry 3D ✕ 医療機器ベンチャーの幹部候補エンジニア募集! https://www.wantedly.com/projects/159442 6