You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2021/01/19 17:35:11 UTC

[GitHub] [airflow] kovaliovsg commented on issue #13754: Configure Azure OATH Authentication

kovaliovsg commented on issue #13754:
URL: https://github.com/apache/airflow/issues/13754#issuecomment-763001815


   Resolved the issue !!
   My assumption was the Airflow will automatically register the user if it doesn't exist in Airflow (It keeps the user's email in Airflow table in database)
   My assumption was wrong, the user has to register for the first time he access Airflow, only then he will be able to authenticate.
   So don't forget to include these parameters in bold in your webserver_congig.py file 
   
   import os
   
   from airflow.configuration import conf
   from flask_appbuilder.security.manager import AUTH_OAUTH
   basedir = os.path.abspath(os.path.dirname(__file__))
   
   SQLALCHEMY_DATABASE_URI = conf.get("core", "SQL_ALCHEMY_CONN")
   CSRF_ENABLED = True
   
   **AUTH_TYPE = AUTH_OAUTH
   AUTH_USER_REGISTRATION_ROLE = "Admin"
   AUTH_USER_REGISTRATION = True**
   
   OAUTH_PROVIDERS = [
   {
     "name": "azure",
     "icon": "fa-user-o",
     "token_key": "access_token",
     "remote_app": { .........................................................................
   ............................................................................................................


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org