I am trying to get Airflow running on a local Docker Desktop for Mac installation using the Quick Start instructions for a Docker installation at https://airflow.apache.org/docs/apache-airflow/stable/start/docker.html. The install seems to go correctly, but when I start up the services using docker-compose up
, all the services launch except for the webserver. That service starts, but then fails and restarts, over and over. The log shows this error:
EDIT: I found the issue in case someone else runs into it. The default configuration of Docker desktop for Mac doesn't allocate enough memory to run webserver. I bumped up the memory allocation in Docker, restarted everything, and all was good.
How do I restart Airflow Services? You can do start/stop/restart actions on an Airflow service and the commands used for each service are given below: Run sudo monit <action> scheduler for Airflow Scheduler. Run sudo monit <action> webserver for Airflow Webserver.
If you run Airflow locally and start it with the two commands airflow scheduler and airflow webserver , then those processes will run in the foreground. So, simply hitting Ctrl-C for each of them should terminate them and all their child processes.
Running Airflow in Docker is much easier compared to running it on Windows without Docker. It is because Docker saves up time needed for installing necessary dependencies which are required for running data pipelines.
increasing the memory configuration of the docker worked for me
Edit: Docs for docker configurations on mac: https://docs.docker.com/docker-for-mac/
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With