I have two clients set up (Client1, Client2) with their own database connections (DB1, DB2). Client1 already has users, and I would like these users to be able to log in to Client2, but do not want users from Client2 to be able to log in to Client1.
I currently have Client1 set up with only the DB1 connection, and Client2 set up with DB1 and DB2 connections. However, when a user signs up for Client2, their user is being created in DB1 instead of DB2.
How can I choose which connection new users are created in?
I am using the Auth0 Wordpress plugin which is currently using Lock 10. I would prefer to have new users stay in their clients respective DB, not signed up in both databases. Would a rule work for this? I looked at the
defaultDatabaseConnection setting, but this still restricts to a single database. It looks like the WordPress plugin will allow me to user Lock 9. Would I be able to get the functionality I am looking for with Lock 9?
Another option I have thought about is consolidating all users into one connection and using metadata to differentiate between them. However, I am not sure how this would work through the WordPress plugin.