This is my first DAG created to play with airflow.
Install docker if you don't have one. Get the container of airflow, I have used puckel/docker-airflow.
docker pull puckel/docker-airflow
Check if you have the image now
docker images
Now you can run the image
docker run -d -p 8080:8080 puckel/docker-airflow webserver
Airflow dashboard can be found visiting http://localhost:8080/admin/
Check the docker name by
docker ps
Stop this if you want by
docker stop <container name>
So your container is up and running. Now, how do we start defining DAGs?
Create the python DAG file and then give the path of that file while running again
docker run -d -p 8080:8080 -v /path/to/dags/on/your/local/machine/:/usr/local/airflow/dags puckel/docker-airflow webserver
Hope that helps!