Skip to content

Commit 1281bc3

Browse files
Merge pull request #251937 from jonburchel/2023-09-18-create-private-requirement-package-for-airflow
2023 09 18 create private requirement package for airflow
2 parents a24cef6 + 87ee94e commit 1281bc3

File tree

3 files changed

+45
-2
lines changed

3 files changed

+45
-2
lines changed

articles/data-factory/TOC.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1322,11 +1322,13 @@ items:
13221322
href: how-does-managed-airflow-work.md
13231323
- name: How to change the Airflow password
13241324
href: password-change-airflow.md
1325+
- name: Create a private requirement Package
1326+
href: airflow-create-private-requirement-package.md
13251327
- name: Enable Azure Key Vault for Airflow
13261328
href: enable-azure-key-vault-for-managed-airflow.md
1327-
- name: Add Kubernetes secret to access a private container registry
1329+
- name: Kubernetes secret to access private container registry
13281330
href: kubernetes-secret-pull-image-from-private-container-registry.md
1329-
- name: Rest APIs for managing the Airflow integrated runtime
1331+
- name: Rest APIs for the Airflow integrated runtime
13301332
href: rest-apis-for-airflow-integrated-runtime.md
13311333
- name: Pricing
13321334
href: airflow-pricing.md
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
---
2+
title: Create a private requirement package for Managed Airflow
3+
description: This article provides step-by-step instructions for how to create a private requirement package within a Managed Airflow environment in Azure Data Factory.
4+
author: nabhishek
5+
ms.author: abnarain
6+
ms.reviewer: jburchel
7+
ms.service: data-factory
8+
ms.topic: how-to
9+
ms.date: 09/23/2023
10+
---
11+
12+
# Create a private requirement package for Managed Airflow
13+
14+
[!INCLUDE[appliesto-adf-xxx-md](includes/appliesto-adf-xxx-md.md)]
15+
16+
Creating a private requirement package within a Managed Airflow environment involves several key steps to ensure seamless integration. By following these steps, you can effectively manage and utilize your own custom packages. If you're interested in learning how to create a custom package in Python, refer to the guide [Creating a package in python](https://airflow.apache.org/docs/apache-airflow/stable/administration-and-deployment/modules_management.html#creating-a-package-in-python).
17+
18+
## Step 1: Create a storage container
19+
20+
Use the steps described in [Manage blob containers using the Azure portal](/azure/storage/blobs/blob-containers-portal) to create a storage account for the package.
21+
22+
## Step 2: Upload the private package into your storage account
23+
24+
1. Navigate to the designated container where you intend to store your Airflow DAGs and Plugins.
25+
1. Upload your private package file to the container. Common file formats include zip, whl, or tar.gz. Place the file within either the 'Dags' or 'Plugins' folder, as appropriate.
26+
27+
## Step 3: Add your private package as a requirement
28+
29+
1. Add your private package as a requirement in the requirements.txt file. Add this file if it doesn't already exist.
30+
1. Be sure to prepend the prefix "**/opt/airflow**" to the package path. For instance, if your private package resides at _/dats/test/private.wht_, your requirements.txt file should feature the requirement _/opt/airflow/dags/test/private.wht_.
31+
32+
## Step 4: Import your folder to an Airflow integrated runtime (IR) environment
33+
34+
When performing the import of your folder into an Airflow IR environment, ensure that you enable the import requirements checkbox.
35+
36+
:::image type="content" source="media/airflow-create-private-requirement-package/import-requirements-checkbox.png" alt-text="Screenshot showing the import dialog for an Airflow integrated runtime environment, with the Import requirements checkbox checked.":::
37+
38+
## Next steps
39+
40+
- [What is Azure Data Factory Managed Airflow?](concept-managed-airflow.md)
41+
- [Run an existing pipeline with Airflow](tutorial-run-existing-pipeline-with-airflow.md)
21.8 KB
Loading

0 commit comments

Comments
 (0)