Commit 3f43cb8e authored by one_jh's avatar one_jh
Browse files

Add new file

parent e78b3ce9
from airflow.operators.bash_operator import BashOperator
from airflow.models import DAG
from datetime import datetime, timedelta
args = {
'owner': 'airflow',
'start_date': datetime(2018, 11, 1)
}
dag = DAG(
dag_id='hello_airflow',
default_args=args,
schedule_interval='@once')
# Bash Operator
cmd = 'echo "Hello, Airflow"'
BashOperator(task_id='t1', bash_command=cmd, dag=dag)
# echo """from airflow.operators.bash_operator import BashOperator
# from airflow.models import DAG
# from datetime import datetime, timedelta
# args = {
# 'owner': 'airflow',
# 'start_date': datetime(2018, 11, 1)
# }
# dag = DAG(
# dag_id='hello_airflow',
# default_args=args,
# schedule_interval='@once')
# # Bash Operator
# cmd = 'echo Hello, Airflow'
# BashOperator(task_id='t1', bash_command=cmd, dag=dag)
# """ >> bash_operator.py
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment