You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by po...@apache.org on 2022/01/23 13:22:06 UTC

[airflow] 12/24: Add requirements.txt description (#20048)

This is an automated email from the ASF dual-hosted git repository.

potiuk pushed a commit to branch v2-2-test
in repository https://gitbox.apache.org/repos/asf/airflow.git

commit 346656ff38e8d2b7b94fa879ee86be253194ed48
Author: Dmytro Kazanzhy <dk...@gmail.com>
AuthorDate: Sun Dec 5 23:49:25 2021 +0200

    Add requirements.txt description (#20048)
    
    (cherry picked from commit 7627de383e5cdef91ca0871d8107be4e5f163882)
---
 docs/apache-airflow/howto/operator/python.rst | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/docs/apache-airflow/howto/operator/python.rst b/docs/apache-airflow/howto/operator/python.rst
index ec56b70..170adfe 100644
--- a/docs/apache-airflow/howto/operator/python.rst
+++ b/docs/apache-airflow/howto/operator/python.rst
@@ -80,6 +80,16 @@ Otherwise you won't have access to the most context variables of Airflow in ``op
 If you want the context related to datetime objects like ``data_interval_start`` you can add ``pendulum`` and
 ``lazy_object_proxy``.
 
+If additional parameters for package installation are needed pass them in ``requirements.txt`` as in the example below:
+
+.. code-block::
+
+  SomePackage==0.2.1 --pre --index-url http://some.archives.com/archives
+  AnotherPackage==1.4.3 --no-index --find-links /my/local/archives
+
+All supported options are listed in the `requirements file format <https://pip.pypa.io/en/stable/reference/requirements-file-format/#supported-options>`_.
+
+
 Templating
 ^^^^^^^^^^