potiuk commented on a change in pull request #4938: [AIRFLOW-4117]
Multi-staging Image - Travis CI tests [Step 3/3]
URL: https://github.com/apache/airflow/pull/4938#discussion_r298796980
##########
File path: Dockerfile
##########
@@ -292,28 +320,32 @@ COPY --chown=airflow:airflow airflow/version.py
${AIRFLOW_SOURCES}/airflow/versi
COPY --chown=airflow:airflow airflow/__init__.py
${AIRFLOW_SOURCES}/airflow/__init__.py
COPY --chown=airflow:airflow airflow/bin/airflow
${AIRFLOW_SOURCES}/airflow/bin/airflow
-# Airflow Extras installed
-ARG AIRFLOW_EXTRAS="all"
-ENV AIRFLOW_EXTRAS=${AIRFLOW_EXTRAS}
-RUN echo "Installing with extras: ${AIRFLOW_EXTRAS}."
-
-# First install only dependencies but no Apache Airflow itself
-# This way regular changes in sources of Airflow will not trigger
reinstallation of all dependencies
-# And this Docker layer will be reused between builds.
-RUN pip install --no-use-pep517 -e ".[${AIRFLOW_EXTRAS}]"
+# First upgrade everything to latest version and then run pip install -e
.[extras] to downgrade the
+# dependencies which should not be the latest ones according to setup.py
+RUN pip list --outdated --format=freeze | grep -v '^\-e' | cut -d = -f 1 |
xargs pip install -U && \
Review comment:
@gerardo @Fokko @ashb - in the last version I withdrew that
upgrade-downgrade thing.
It was too confusing to explain and since I added the BUILD_MONTH argument,
it means that at the beginning of every month the first builds will re-test
apt-get install from the scratch (before first commit that month is merged). We
will observe that in two days.
Since we also will have the daily cron job that will run without cache and
will rebuild locally all the images from the scratch - we will be very well
covered for all the scenarios where state of pip-installed deps matter and our
cache-dependency is now pretty safe.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services