问题描述
这是我的气流网络服务器的 systemd 单元文件:
#airflow-webserver.service
[Unit]
Description=Airflow webserver daemon
After=network.target postgresql.service
Wants=postgresql.service
[Service]
#EnvironmentFile=/etc/default/airflow
EnvironmentFile=/home/ubuntu/airflow/airflow.env
User=ubuntu
Group=ubuntu
Type=simple
ExecStart=/home/ubuntu/.local/bin/airflow webserver
Restart=on-failure
RestartSec=5s
PrivateTmp=true
[Install]
WantedBy=multi-user.target
当我跑步时
$ /home/ubuntu/.local/bin/airflow webserver
从命令行启动网络服务器就好了。但是,当我使用
检查系统进程的状态时$ systemctl status airflow-webserver.service
我看到了
● airflow-webserver.service - Airflow webserver daemon
Loaded: loaded (/etc/systemd/system/airflow-webserver.service; enabled; vendor preset: enabled)
Active: activating (auto-restart) (Result: exit-code) since Wed 2021-02-17 02:52:56 UTC; 1s ago
Process: 2010 ExecStart=/home/ubuntu/.local/bin/airflow webserver (code=exited,status=1/FAILURE)
Main PID: 2010 (code=exited,status=1/FAILURE)
这是一个几乎无用的“错误代码”,因为它没有向我展示导致失败的原因,而且我无法从 CLI 复制它。
Ubuntu 20.04.2 LTS
python 3.8.5
airflow 2.0.1
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)