Skip to content

Commit

Permalink
Set a real ref_date to count the 2 months from
Browse files Browse the repository at this point in the history
Signed-off-by: Jose Luis Rivero <[email protected]>
  • Loading branch information
j-rivero committed Nov 13, 2023
1 parent 076f67e commit 33e8fe3
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion jenkins-scripts/docker/lib/docker_generate_dockerfile.bash
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,9 @@ fi
# Bionic|Focal builds were affected by a "gpg: keyserver receive failed" in apt-key execution
# that poisoned a lot of docker cache in different builds and nodes. Force invalidation
# during a couple of month to rotate images
ref_date='2023-11-13'
if [[ "${DISTRO}" == 'bionic' || "${DISTRO}" == 'focal' ]] && \
[[ "$(date '+%s')" -lt "$(date -d '+60 days' '+%s')" ]]; then
[[ "$(date '+%s')" -lt "$(date -d "${ref_date}+60 days" '+%s')" ]]; then
export INVALIDATE_DOCKER_CACHE=true
fi

Expand Down

0 comments on commit 33e8fe3

Please sign in to comment.