ViUR and Google Auth¶
This changes took effect on ViUR >=3.3. In case you’re using a prior version, you need to handle it differently.
Open the Google Cloud Console website as an admin user
Open the API & Services OAuth conset screen menu
Declare your user type and click the “Create” button
Fill in the App information “Save and Continue”
- Click the Button “Add or Remove Scopes” and choose the following scopes:
../auth/userinfo.mail
../auth/userinfo.profile
openid
Note
Those scopes are the general scopes to get user information
Save and Continue
Navigate to API & Services Credentials
Press the button “+ create credentials”
Select “OAuth Client ID”
Enter your application type as “Web Application”
Enter a name for your OAuth 2.0 client
Click the “Add URI” button, under the “Authorized Javascript origins” headline
Enter your redirect URL’s
For deployed Software we recommend:If you want to use the Google LogIn in your development System you will also need to add:Click the “Create” buttton
Copy the client ID of the succes message to your clipboard
Open the main.py of your ViUR project and add the config variable and the id
#.. code-block:: python # # Insert your clientID as String # conf[“viur.user.google.clientID”] = “ ” # # If you are a gsuitecustomer, you can whitelist mails form certain Domains # conf[“viur.user.google.gsuiteDomains”] = [“viur.com”]