How to Use MySQL or PostgreSQL in a Tauri App for Offline Use?

50 points agamycode

Hey everyone,

I’m building a Tauri app and I need help figuring out how to include a MySQL or PostgreSQL database that works offline. Basically, I want the database to be part of the app, like when programs are installed in the Program Files folder on Windows.

Note: I’m specifically looking to use MySQL or PostgreSQL, not SQLite.

  • How can I bundle a MySQL or PostgreSQL database with my Tauri app?
  • What tools or libraries should I use to make this happen?
  • Any tips on managing database updates or migrations in this setup?
  • Are there any big issues or things I should watch out for?