From 48edb7b2586d358344337171ee78fd7cb109a6d9 Mon Sep 17 00:00:00 2001 From: ziv Date: Sun, 9 Jun 2024 20:06:53 +0300 Subject: [PATCH] Add DAG for loading streets data from data.gov --- airflow_server/dags/streets.py | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 airflow_server/dags/streets.py diff --git a/airflow_server/dags/streets.py b/airflow_server/dags/streets.py new file mode 100644 index 0000000..1a9665c --- /dev/null +++ b/airflow_server/dags/streets.py @@ -0,0 +1,20 @@ +from airflow import DAG +import pendulum + +from anyway_etl_airflow.operators.cli_bash_operator import CliBashOperator + + +dag_kwargs = dict( + default_args={ + 'owner': 'airflow', + }, + schedule_interval='@weekly', + catchup=False, + start_date=pendulum.datetime(2024, 1, 1, tz="Asia/Jerusalem"), +) + + +with DAG('load-streets', **dag_kwargs) as load_streets: + CliBashOperator(cmd='anyway-etl anyway-kubectl-exec python3 main.py process streets', + task_id='load-streets' + )