我已经有一个工作流的Airflow实例。我现在正在尝试使用GitHub Enterprise Authentication设置Airflow。就文档而言,可用的资源不多,我在网上找不到任何好的示例,因此遇到了一些麻烦。当我将身份验证设置为false时,Airflow实例工作正常,但是当我尝试打开身份验证并启动Airflow实例时,出现以下错误
CRITICAL - Cannot import authentication module airflow.contrib.auth.backends.github_enterprise_auth. Please correct your authentication backend or disable authentication: No module named 'flask_oauthlib'
airflow.cfg
文件的相关部分如下:
[webserver]
authenticate = True
auth_backend = airflow.contrib.auth.backends.github_enterprise_auth
[github_enterprise]
api_rev = v3
host = github.com
# From your OAuth app
client_id = CLIENT_ID_CODE
client_secret = CLIENT_SECRET_CODE
oauth_callback_route = /oauth/callback
# airflow team in github
# allowed_teams =
我尝试完全重新创建我的虚拟Python环境,并点安装Flask_OAuthlib,但还是没有运气。
有谁知道该怎么做,可以向我解释如何使它工作。
This是我可以找到的唯一有关该主题的文档,但我仍然不清楚。
答案 0 :(得分:0)
我想出了如何获取.valueChanged
模块。我正在通过Docker实例创建Airflow,并且在我的Python虚拟环境中安装了正确的模块,但是我的Dockerfile中没有正确的flask_oauthlib
语句。