18 lines
547 B
Python
18 lines
547 B
Python
from airflow.operators.bash import BashOperator
|
|
import pendulum
|
|
from airflow import DAG
|
|
|
|
with DAG(
|
|
dag_id="increase_decrease_city_region_dag",
|
|
# 每月的最后一天运行
|
|
schedule="0 10 L * *",
|
|
start_date=pendulum.datetime(2024, 5, 30, tz="Asia/Shanghai"),
|
|
description="城市区域涨跌幅数据统计",
|
|
catchup=True
|
|
) as dag:
|
|
t1 = BashOperator(
|
|
task_id='increase_decrease_city_region',
|
|
bash_command='python /opt/airflow/dags/repo/dags/stat/cityPrice/increase_decrease_city_region.py',
|
|
)
|
|
t1
|