1

我在 Ubuntu 上运行 Airflow 1.10.12。Airflow 使用本地执行程序和 MySql 运行良好。为了进行一些测试,我已经使用 RabbitMQ 迁移到 Celery 执行器。根据教程,这是我的配置文件:

[core]
executor = CeleryExecutor
[celery]
broker_url = pyamqp://rabbitmq:rabbitmq@localhost/
result_backend = db+mysql+pymysql://airflow:airflow@localhost:3306/airflow_db

但是当我运行时:

airflow webserver

抛出以下错误:

Traceback (most recent call last):
  File "/usr/local/bin/airflow", line 37, in <module>
    args.func(args)
  File "/usr/local/lib/python3.8/dist-packages/airflow/utils/cli.py", line 76, in wrapper
    return f(*args, **kwargs)
  File "/usr/local/lib/python3.8/dist-packages/airflow/bin/cli.py", line 1076, in webserver
    app = cached_app_rbac(None) if settings.RBAC else cached_app(None)
  File "/usr/local/lib/python3.8/dist-packages/airflow/www_rbac/app.py", line 300, in cached_app
    app, _ = create_app(config, session, testing)
  File "/usr/local/lib/python3.8/dist-packages/airflow/www_rbac/app.py", line 65, in create_app
    app.config.from_pyfile(settings.WEBSERVER_CONFIG, silent=True)
  File "/usr/local/lib/python3.8/dist-packages/flask/config.py", line 132, in from_pyfile
    exec(compile(config_file.read(), filename, "exec"), d.__dict__)
  File "/home/helia/airflow/webserver_config.py", line 21, in <module>
    from airflow.www.fab_security.manager import AUTH_DB
ModuleNotFoundError: No module named 'airflow.www.fab_security'
4

0 回答 0