新增小区43同步至100高效方式
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
from airflow.operators.bash import BashOperator
|
||||
import pendulum
|
||||
from airflow import DAG
|
||||
|
||||
with DAG(
|
||||
"didata_sync_dag",
|
||||
# 每月28日3点整分运行
|
||||
schedule_interval="0 3 28 * *",
|
||||
start_date=pendulum.datetime(2022, 8, 22, tz="Asia/Shanghai"),
|
||||
catchup=True,
|
||||
description="地数相关数据同步type: district或office"
|
||||
) as dag:
|
||||
t1 = BashOperator(
|
||||
task_id='didata_sync_dag',
|
||||
bash_command='python /opt/airflow/dags/repo/dags/business/business/didata_sync.py {{dag_run.conf["type"] if "type" in dag_run.conf}}',
|
||||
)
|
||||
t1
|
||||
Reference in New Issue
Block a user