Sharing databases is something that’s convenient to do within your local development environment especially if you’re working with multiple machines.
If for whatever reason you’re looking to do this with a staging environment or production environment, then this is not the way to do it. There are strategies like database replication and the like that are meant for that, and that are far beyond the scope of this post.
Instead, this is primarily intended for systems that you have, likely on the same network, and that you swap between during the day.

