Created
July 13, 2022 09:37
-
-
Save cra/035873804ad481322c7e537eb9ef89c0 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pendulum | |
from airflow import DAG | |
from airflow.operators.trigger_dagrun import TriggerDagRunOperator | |
dag = DAG( | |
dag_id='i_will_trigger', | |
schedule_interval=None, | |
start_date=pendulum.parse('2022-07-13'), | |
) | |
task = TriggerDagRunOperator( | |
task_id='run_me', | |
trigger_dag_id='triggable', | |
conf={'hello': 'goodbye'}, | |
dag=dag, | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pendulum | |
from airflow import DAG | |
from airflow.operators.bash import BashOperator | |
dag = DAG( | |
dag_id='triggable', | |
params={'hello': 'there'}, | |
schedule_interval=None, | |
start_date=pendulum.parse('2022-07-13') | |
) | |
task = BashOperator(task_id='aaa', dag=dag, bash_command='echo {{ params.hello }}') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
log excerpt