Installing Apache Airflow in local – Mac OS

PreRequisite

Python version should be above 3.6

Steps for Installation

  1. check for python3 version in the terminal
    • python3 --version
  2. Version should be above 3.6
  3. Create new folder – mkdir apache-airflow
  4. cd apache-airflow
  5. Create the python environment
  6. python3 -m venv py_env
  7. Activate the python environment
  8. command – source py_env/bin/activate
  9. Install Apache airflow from github from https://github.com/apache/airflow
  10. copy the install command and paste in your terminal
  11. pip install 'apache-airflow==2.8.0' --constraint "https://raw.githubusercontent.com/apache/airflow/constraints-2.8.0/constraints-3.8.txt"
  12. Create sqllite database
  13. airflow db init to initialize db for airflow
  14. Start airflow webserver airflow webserver -p 8080
  15. check localhost to see the UI of airflow
  16. Use airflow users create and provide th details to create user to login
  17. In other terminal, going the same folder start the scheduler airflow scheduler

Leave a comment