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

potiuk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/airflow.git


The following commit(s) were added to refs/heads/master by this push:
     new 0038660  Fixes pull error on building tagged image (#12378)
0038660 is described below

commit 0038660fddc99f454a8ecf4de53be9848f7ddc5d
Author: Jarek Potiuk <[email protected]>
AuthorDate: Mon Nov 16 02:26:36 2020 +0100

    Fixes pull error on building tagged image (#12378)
    
    When building tagged image on DockerHub the build has been
    failing as it was trying to pull cached version of prod image
    but the tagged image should be built from scratch so cache should
    be disabled.
    
    Fixes #12263
---
 scripts/ci/images/ci_build_dockerhub.sh | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/scripts/ci/images/ci_build_dockerhub.sh 
b/scripts/ci/images/ci_build_dockerhub.sh
index 501ec96..cd12415 100755
--- a/scripts/ci/images/ci_build_dockerhub.sh
+++ b/scripts/ci/images/ci_build_dockerhub.sh
@@ -51,6 +51,11 @@ export FORCE_AIRFLOW_PROD_BASE_TAG
 
 readonly FORCE_AIRFLOW_PROD_BASE_TAG
 
+if [[ "${FORCE_AIRFLOW_PROD_BASE_TAG}" =~ [0-9].* ]]; then
+    # Disable cache if we are building a tagged version
+    export DOCKER_CACHE="disabled"
+fi
+
 # shellcheck source=scripts/ci/libraries/_script_init.sh
 . "$( dirname "${BASH_SOURCE[0]}" )/../libraries/_script_init.sh"
 

Reply via email to