This file contains hidden or 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
from datetime import datetime | |
from airflow import DAG | |
from airflow.operators.python_operator import PythonOperator | |
from airflow.hooks.S3_hook import S3Hook | |
def upload_file(ds, **kwargs): | |
with open("/tmp/test.txt", "w") as fp: | |
# Creating the content and flushing it. |
This file contains hidden or 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
{ | |
"aws_access_key_id":"minio_admin", | |
"aws_secret_access_key": "minio_password", | |
"host": "http://myminio:9000" | |
} |
This file contains hidden or 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
Rest endpoint: http://mynifi:8080/nifi-api/processors/1462a26f-0000-0000-0000-35550911fe94 | |
Response: <Response [200]> | |
Processor: {'revision': {'version': 0}, 'id': '1462a26f-bf20-391a-a4d9-35550911fe94', 'uri': 'http://mynifi:8080/nifi-api/processors/1462a26f-0000-0000-0000-35550911fe94', 'position': {'x': 936.0, 'y': 304.0}, 'permissions': {'canRead': True, 'canWrite': True}, 'bulletins': [], .... |
This file contains hidden or 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
from airflow import DAG | |
from airflow.operators.python_operator import PythonOperator | |
from airflow.hooks.base_hook import BaseHook | |
from airflow.utils.trigger_rule import TriggerRule | |
import json | |
from datetime import datetime | |
import requests | |
from urllib3.exceptions import InsecureRequestWarning | |
requests.packages.urllib3.disable_warnings(category=InsecureRequestWarning) # disable warnings |
This file contains hidden or 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
from airflow import DAG | |
# path for Airflow version 1.10.9: | |
from airflow.operators.postgres_operator import PostgresOperator | |
# path for Airflow version 2.4.0: | |
# from airflow.providers.postgres.operators.postgres import PostgresOperator | |
import datetime | |
with DAG( | |
dag_id="hello_postgres_postgres_operator", | |
start_date=datetime.datetime(2021, 12, 17), |
This file contains hidden or 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
boto3 |
This file contains hidden or 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
[default] | |
accessKey=minio_admin | |
secretKey=minio_password |
This file contains hidden or 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
SELECT 1 as one; |
This file contains hidden or 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
SELECT 1; |
This file contains hidden or 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
docker inspect b5f16b1d7bc3 | grep IPAddresss |
NewerOlder