diff --git a/script/actions_utils/container_timestamp_check.sh b/script/actions_utils/container_timestamp_check.sh index 902171e7f..a36181f5f 100755 --- a/script/actions_utils/container_timestamp_check.sh +++ b/script/actions_utils/container_timestamp_check.sh @@ -58,7 +58,8 @@ ENV_JSON=$(curl \ -H "Authorization: token ${TOKEN}" \ "${ENV_IMG_ENDPOINT_URL}") -ENV_IMG_TIMESTAMP=$(echo "${ENV_JSON}" | jq -r 'sort_by(.updated_at)[-1].updated_at') +ENV_IMG_TIMESTAMP=$(echo "${ENV_JSON}" | \ +jq -rc '.[] | select(.metadata.container.tags[] | contains("latest")).updated_at' echo "Base timestamp: ${BASE_IMG_TIMESTAMP}" echo "Env timestamp: ${ENV_IMG_TIMESTAMP}"