django-allauth provider allowing users to log-in with phone number.
- Install django-allauth-sms package.
pip install git+https://github.com/yuriiz/django-allauth-sms.git
- Configure django-allauth. See https://django-allauth.readthedocs.io/en/latest/installation.html
- Configure django-sms backend. See https://pypi.org/project/django-sms/
- Add
allauth_sms
toINSTALLED_APPS
INSTALLED_APPS = {
...
'allauth',
'allauth.account',
'allauth.socialaccount',
...
'allauth_sms'
...
}
- Use "SMS" option at allauth's
account_login
view.
git clone https://github.com/yuriiz/django-allauth-sms.git
cd django-allauth.sms
pip install requirements.txt
./manage.py migrate
./manage.py runserver
Verification codes will be printed to console with sms.backends.console.SmsBackend
.