Created
March 26, 2022 13:13
-
-
Save febridev/41160d504310b6c2463c44b6b6b84fc7 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 os | |
from dataIngestion import download_from_kaggle | |
from datetime import datetime | |
from airflow import DAG | |
from airflow.operators.bash import BashOperator | |
from airflow.operators.python import PythonOperator | |
# from dotenv import load_dotenv | |
# load_dotenv() | |
# kaggle_username = os.getenv('kaggle_username') | |
# kaggle_key = os.getenv('kaggle_key') | |
local_workflow = DAG( | |
"dezoomcampProject", | |
schedule_interval="@once", | |
catchup = False, | |
start_date = datetime(2022,3,26), | |
max_active_runs = 3 | |
) | |
with local_workflow: | |
downloadDataset=PythonOperator( | |
task_id="dataset_download", | |
retries=1, | |
python_callable=download_from_kaggle | |
) | |
downloadDataset |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment