MWAA Installing python packages in wrong place

0

I am running a MWAA 2.2.2 instance, and I have correctly put my requirements.txt file in the s3 bucket as instructed by the docs. When the instance spins up, the extra requirements are being installed in /usr/local/airflow/.local/bin instead of where they should be installed which is /usr/local/airflow/requirements/requirements.txt. (according to the docs here).

2022-03-31T12:58:42.311-06:00	Installing collected packages: fastavro

2022-03-31T12:58:42.394-06:00   WARNING: The script fastavro is installed in '/usr/local/airflow/.local/bin' which is not on PATH.
gefragt vor 2 Jahren338 Aufrufe
1 Antwort
0

Hello,

Your packages are being installed in the right location. If you are referring to the line here:

$ pip3 download -r "$AIRFLOW_HOME/dags/requirements.txt" -d "$AIRFLOW_HOME/plugins"

From our documentation 1, this is where PIP will find your requirements.txt file. It then installs the packages you have listed in the requirements.txt file into the location you are seeing. This is the expected behavior.

AWS
Andrew
beantwortet vor einem Jahr

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen