My goal: Launch Postgres (via postgresql_embedded) inside tauri::Builder.setup, and connect to it either from a sidecar or the host (e.g., with psql).
How I've succeeded so far:
I can initialize postgres outside of the tauri::Builder chain and then connect to it from a Tauri sidecar or psql.
Where I'm stuck:
When I put Postgres initialization inside tauri::Builder.setup, I am able to interact with it (e.g., using sqlx) inside my Tauri app, but not from a sidecar or the host. I would like to start it inside setup because I access some app configuration properties during Postgres initialization. The database URL that I pass to either the sidecar or psql for testing looks like this: postgresql://postgres:REDACTED@localhost:40255/postgres