17 lines
493 B
Python
17 lines
493 B
Python
from airflow import DAG
|
|
from datetime import datetime
|
|
from airflow.operators.bash import BashOperator
|
|
|
|
|
|
class MyDAG(DAG):
|
|
print("enter in MyDAG")
|
|
def __init__(self, *args, **kwargs):
|
|
print('SUCCESS')
|
|
super().__init__(
|
|
*args, **kwargs
|
|
)
|
|
BashOperator(
|
|
task_id='install_required',
|
|
bash_command='pip install -I -r requirements.txt -i https://repo.fangjia.com/repository/pypi-public/simple/',
|
|
)
|
|
print('OK') |