https://supabase.com/ logo
#help
Title
# help
k

kjellski

04/05/2022, 7:07 AM
I'm asking myself on how to integrate the whole supabase setup in my codebase and was just wondering about how to keep migrations etc on the code side of things. Is there a recommended way to integrate that or am I supposed to just keep it all on the supabase website interface?
n

Needle

04/05/2022, 7:07 AM
Hello @kjellski! This thread has been automatically created from your message in #843999948717555735 a ``few seconds ago``. Pinging @User so that they see this as well! Want to unsubscribe from this thread? Right-click the thread in Discord (or use the ... menu) and select Leave Thread to unsubscribe from future updates. Want to change the title? Use the
/title
command! We have solved your problem? Click the button below to archive it.
b

barry

04/05/2022, 7:08 AM
Do you mean configuration on the codebase instead of supabase's site?
n

Needle

04/05/2022, 7:08 AM
kjellski (2022-04-05)
k

kjellski

04/05/2022, 7:08 AM
For context, I'm used to infrastructure as code and would treat the db as such. But I can't seem to find documentation that sais something like that would be done in ways XYZ
I am having a hard time framing the question, sorry. I'm not supposed to keep the migrations etc alongside with my code right?
b

barry

04/05/2022, 7:10 AM
What do you mean by migrations exactly
k

kjellski

04/05/2022, 7:13 AM
Suppose I'd be using a orm that supports migrations like
typeorm
- the db setup would be done from a step in my ci pipeline that's looking if the db is migrated to the latest version in code. But currently I'm just seeing the changes made to the db always done on the website of supabase. So I don't get the benefits of versioning etc. is this the recommended way?
b

barry

04/05/2022, 7:14 AM
I'm really confused what you're even asking, what I know is Supabase just makes my life easier and I don't have to handle all this database auth stuff with simple methods 🤣
k

kjellski

04/05/2022, 7:14 AM
Also,
supabase init
will produce a folder not to be checked in and I'm wondering if I should keep anything except a dependency to it in my codebase 😅
b

barry

04/05/2022, 7:15 AM
I didn't even use supabase init, I just made a file in the lib folder and connected it to supabase.
k

kjellski

04/05/2022, 7:15 AM
How do you change tables and columns?
b

barry

04/05/2022, 7:15 AM
That's all predefined in the supabase panel
You make them, set types
That's not handled in your codebase
k

kjellski

04/05/2022, 7:16 AM
👍 but that's the way right?
b

barry

04/05/2022, 7:16 AM
Yeah
I think i saw a 90 minute video by Let's Learn with Jason on Supabase
That + documentation was enough for me to get going.
k

kjellski

04/05/2022, 7:16 AM
Alright, thank you a ton! I really appreciate your patience!
b

barry

04/05/2022, 7:17 AM
No worries
k

kjellski

04/05/2022, 7:17 AM
I was just wondering if there is no intended way to keep the codebase alongside the db migrations etc...
🙏 thank you!
n

Needle

04/05/2022, 7:17 AM
Thread was archived by @kjellski. Anyone can send a message to unarchive it.
k

kjellski

04/05/2022, 2:42 PM
Okay
c

chrisb2244

04/05/2022, 6:46 PM
I also have the same question - it would be nice if (and perhaps there already is) there was a way to store (e.g. in git) the history of schema changing SQL statements for the db. If the statements are directly executed on the app.supabase.io page, then it can be difficult to reproduce or trace the current structure/functions/triggers etc. I think that's what kjellski was asking for?