Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Production Docker Image AIRFLOW_INSTALL_VERSION does not overwrite AIRFLOW_VERSION environment variable #8612

Closed
ldacey opened this issue Apr 28, 2020 · 2 comments · Fixed by #12875
Assignees
Labels
area:production-image Production image improvements and fixes kind:bug This is a clearly a bug

Comments

@ldacey
Copy link
Contributor

ldacey commented Apr 28, 2020

Apache Airflow version: 1.10.10

What happened:
When I look at environment variables within my Airflow containers, I see AIRFLOW_VERSION="2.0.0.dev0"

What you expected to happen:
Since I built the image with AIRFLOW_INSTALL_VERSION="==1.10.10" , I would expect any reference to the Airflow version to reflect 1.10.10 and not 2.0.0.

How to reproduce it:
Build an image with a specific AIRFLOW_INSTALL_VERSION and then exec into it and printenv or inspect the container and you will see AIRFLOW_VERSION="2.0.0.dev0". It does not appear like this env var impacts anything and it is hard coded to 2.0.0.dev0 at the moment. Most likely, this variable should be replaced with the AIRFLOW_INSTALL_VERSION instead.

docker build . \
--build-arg AIRFLOW_INSTALL_SOURCES="apache-airflow" \
--build-arg AIRFLOW_INSTALL_VERSION="==1.10.10" 

/label area:production-image

@ldacey ldacey added the kind:bug This is a clearly a bug label Apr 28, 2020
@boring-cyborg
Copy link

boring-cyborg bot commented Apr 28, 2020

Thanks for opening your first issue here! Be sure to follow the issue template!

@potiuk potiuk added the area:production-image Production image improvements and fixes label Apr 28, 2020
@potiuk potiuk self-assigned this Apr 28, 2020
@potiuk potiuk added this to the Airflow 1.10.11 milestone Jun 26, 2020
@kaxil kaxil modified the milestones: Airflow 1.10.12, Airflow 1.10.13 Aug 3, 2020
potiuk added a commit to PolideaInternal/airflow that referenced this issue Dec 7, 2020
This change clarifies that AIRFLOW_VERSION should be passed
together with AIRFLOW_INSTALL_VERSION when the Docker image
is build.

Fixes apache#8612
@potiuk
Copy link
Member

potiuk commented Dec 7, 2020

I finally looked at it - there is not an easy way to do it automatically. I just updated breeze to automatically set, and updated the documentation and examples to clarify that whenever you run AIRFLOW_VERSION, you should also specify AIRFOW_VERSION build arg. PR #12875

potiuk added a commit that referenced this issue Dec 7, 2020
This change clarifies that AIRFLOW_VERSION should be passed
together with AIRFLOW_INSTALL_VERSION when the Docker image
is build.

Fixes #8612
potiuk added a commit that referenced this issue Dec 13, 2020
This change clarifies that AIRFLOW_VERSION should be passed
together with AIRFLOW_INSTALL_VERSION when the Docker image
is build.

Fixes #8612

(cherry picked from commit 1dcef78)
kaxil pushed a commit that referenced this issue Jan 21, 2021
This change clarifies that AIRFLOW_VERSION should be passed
together with AIRFLOW_INSTALL_VERSION when the Docker image
is build.

Fixes #8612

(cherry picked from commit 1dcef78)
kaxil pushed a commit that referenced this issue Jan 22, 2021
This change clarifies that AIRFLOW_VERSION should be passed
together with AIRFLOW_INSTALL_VERSION when the Docker image
is build.

Fixes #8612

(cherry picked from commit 1dcef78)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:production-image Production image improvements and fixes kind:bug This is a clearly a bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants