Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
from airflow_breeze.global_constants import (
ALLOWED_DEBIAN_VERSIONS,
ALLOWED_PLATFORMS,
ALLOWED_PYTHON_MAJOR_MINOR_VERSIONS,
APACHE_AIRFLOW_GITHUB_REPOSITORY,
CURRENT_PYTHON_MAJOR_MINOR_VERSIONS,
DEFAULT_PYTHON_MAJOR_MINOR_VERSION,
Expand Down Expand Up @@ -1368,19 +1369,18 @@ def release_prod_images(
f"{dockerhub_repo}:{airflow_version}-python{python}",
f"{dockerhub_repo}:latest-python{python}",
)
if python == DEFAULT_PYTHON_MAJOR_MINOR_VERSION:
# only tag latest "default" image when we build default python version
# otherwise if the non-default images complete before the default one, their jobs will fail
if slim_images:
alias_image(
f"{dockerhub_repo}:slim-{airflow_version}",
f"{dockerhub_repo}:slim-latest",
)
else:
alias_image(
f"{dockerhub_repo}:{airflow_version}",
f"{dockerhub_repo}:latest",
)
if python == ALLOWED_PYTHON_MAJOR_MINOR_VERSIONS[-1]:
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BTW. I also found that this if was wrongly indented (but since we always ran one job per python version in CI, it was not discovered.

# only tag latest "default" image when we build the latest allowed python version
if slim_images:
alias_image(
f"{dockerhub_repo}:slim-{airflow_version}",
f"{dockerhub_repo}:slim-latest",
)
else:
alias_image(
f"{dockerhub_repo}:{airflow_version}",
f"{dockerhub_repo}:latest",
)


def is_package_in_dist(dist_files: list[str], package: str) -> bool:
Expand Down
8 changes: 8 additions & 0 deletions docs/docker-stack/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,14 @@ Airflow 2.8
working with ``Debian Bookworm``. While all reference images of Airflow 2.8.0 are built on ``Debian Bookworm``,
it is still possible to build deprecated custom ``Debian Bullseye`` based image in 2.8.0 following the

* The "latest" image (i.e. default Airflow image when ``apache/airflow`` is used or
``apache/airflow:slim-latest``) uses now the newest supported Python version. Previously it was using
the "default" Python version which was Python 3.8 as of Airflow 2.7. With Airflow reference images
released for Airflow 2.8.0, the images are going to use Python 3.11 as this is the latest supported
version for Airflow 2.8 line. Users can use Python 3.8 by using ``apache/airflow:2.8.0-python3.8`` and
``apache/airflow:slim-2.8.0-python-3.8`` images respectively so while the change is potentially
breaking, it is very easy to switch to the previous behaviour.


Airflow 2.7
~~~~~~~~~~~
Expand Down