Skip to content

Commit

Permalink
Merge pull request #59 from ziv17/2665-cities-from-data.gov
Browse files Browse the repository at this point in the history
 Add DAG for loading citiess data from data.gov
  • Loading branch information
atalyaalon authored Aug 15, 2024
2 parents eb1bf43 + 84276e1 commit c3ff25a
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 0 deletions.
20 changes: 20 additions & 0 deletions airflow_server/dags/cities.py
Original file line number Diff line number Diff line change
@@ -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='@monthly',
catchup=False,
start_date=pendulum.datetime(2024, 1, 1, tz="Asia/Jerusalem"),
)


with DAG('load-cities', **dag_kwargs) as load_cities:
CliBashOperator(cmd='anyway-etl anyway-kubectl-exec python3 main.py process cities',
task_id='load-cities'
)
20 changes: 20 additions & 0 deletions airflow_server/dags/streets.py
Original file line number Diff line number Diff line change
@@ -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'
)

0 comments on commit c3ff25a

Please sign in to comment.