From 0a411bbba552440426db738af1914bf5e1746dc4 Mon Sep 17 00:00:00 2001 From: Federico Capoano Date: Sat, 24 Aug 2024 12:37:50 -0400 Subject: [PATCH] [docs] Revisited social login and saml a bit --- docs/user/saml.rst | 13 ++++++++++--- docs/user/social_login.rst | 11 +++++++++-- 2 files changed, 19 insertions(+), 5 deletions(-) diff --git a/docs/user/saml.rst b/docs/user/saml.rst index a1ffe933..f4a98ee5 100644 --- a/docs/user/saml.rst +++ b/docs/user/saml.rst @@ -49,16 +49,23 @@ Setup Install required system dependencies: -.. code-block:: shell +:: sudo apt install xmlsec1 -Install Python dependencies: +Install the SAML dependencies in the python environment used by OpenWISP: -.. code-block:: shell +:: + + # by default, in instances deployed + # via ansible-openwisp2, the python env + # is in /opt/openwisp2/env/ + source /opt/openwisp2/env/bin/activate pip install openwisp-radius[saml] +.. include:: /partials/settings-note.rst + Ensure your ``settings.py`` looks like the following: .. code-block:: python diff --git a/docs/user/social_login.rst b/docs/user/social_login.rst index c26610b0..8978ccfb 100644 --- a/docs/user/social_login.rst +++ b/docs/user/social_login.rst @@ -20,7 +20,7 @@ perform the submit action of the login form: ``username`` should obviously used for the username field, while ``token`` should be used for the password field. -The internal REST API of openwisp-radius will recognize the token and +The internal REST API of OpenWISP RADIUS will recognize the token and authorize the user. This kind of implementation allows to implement the social login with any @@ -39,12 +39,19 @@ the user is signing-in with a social network. Setup ----- -Install ``django-allauth``: +Install ``django-allauth`` in the python environment used by OpenWISP: :: + # by default, in instances deployed + # via ansible-openwisp2, the python env + # is in /opt/openwisp2/env/ + source /opt/openwisp2/env/bin/activate + pip install django-allauth[socialaccount] +.. include:: /partials/settings-note.rst + Ensure your ``settings.py`` looks like the following (we will show how to configure of the Facebook social provider):