[Django]-Authenticate users across Django projects – where to begin?

5👍

No, you don’t need a separate package. Just use Django’s built-in multi-database handling. Check out: https://docs.djangoproject.com/en/dev/topics/db/multi-db/.

Essentially, you designate one of your databases as the one that’s going to store the user data and make sure that database is added to each of your other projects. Then set up a router that checks for app_label=='auth' and route to the “user” database for those instances. There’s an example in the docs.

Leave a comment