Untitled

 avatar
unknown
plain_text
2 years ago
471 B
9
Indexable
from datetime import datetime
from airflow import DAG
from airflow.operators.python_operator import PythonOperator

def print_hello():
    return 'Hello world from first Airflow DAG!'

dag123 = DAG('hello_world', description='Hello World DAG!!',
          schedule_interval='0 12 * * *',
          start_date=datetime(2023, 4, 26), catchup=False)

hello_operator = PythonOperator(task_id='hello_task', python_callable=print_hello, dag=dag123)

hello_operator
Editor is loading...