airflowairflow-webserver

Remove multiple Airflow installs


I think I have multiple Airflow installs. They might be conflicting. I restarted airflow-webserver and airflow-scheduler. When I run "airflow scheduler" it says: Connection in use: ('0.0.0.0', 8793).

My airflow.cfg is in this location: /home/airflow/airflow

It shows:
dags_folder = /var/foo/dags
endpoint_url = http://localhost:8080
web_server_host = 0.0.0.0
web_server_port = 8080
base_url = http://airflow.foo.lan:8080

On the server there's also another airflow folder inside of: /home/dev/
It shows:
dags_folder = /home/dev/airflow/dags
endpoint_url = http://localhost:8080
web_server_host = 0.0.0.0
web_server_port = 8080
base_url = http://localhost:8080

Does one need to be removed or turned off?


Solution

  • You can specify your airflow home by exposing the env var AIRFLOW_HOME:

    AIRFLOW_HOME=/path/to/home airflow scheduler
    AIRFLOW_HOME=/path/to/home airflow webserver
    

    and Airflow will use the conf $AIRFLOW_HOME/airflow.cfg.