@@ -6,10 +6,18 @@ BRANCH=$3
6
6
REPO_NAME=$4
7
7
8
8
REPO_ROOT=$( git rev-parse --show-toplevel)
9
- # Declare and initialize the image-skipping-logger.sh
10
- export SKIPPED_LOG_PATH=" $REPO_ROOT /skipped-images.txt"
11
- source " $REPO_ROOT /ci/image-skipping-logger.sh"
12
- init_skipped_log
9
+ # Declare and initialize the image skipping log file (This does not commit)
10
+ export SKIPPED_LOG=" $REPO_ROOT /skipped-images.txt"
11
+
12
+ init_skipped_log () {
13
+ mkdir -p " $( dirname " $SKIPPED_LOG " ) "
14
+ touch " $SKIPPED_LOG "
15
+ }
16
+
17
+ log_skipped_image () {
18
+ local image_name=" $1 "
19
+ echo " :x: — No matching sha for $image_name " >> " $SKIPPED_LOG "
20
+ }
13
21
14
22
# Fetch the latest commit hash (or use the user-provided one)
15
23
fetch_latest_hash () {
@@ -109,6 +117,8 @@ update_runtime_images() {
109
117
done
110
118
}
111
119
120
+ init_skipped_log
121
+
112
122
PARAMS_ENV_PATH=" $REPO_ROOT /manifests/base/params.env"
113
123
# In case the digest updater function is triggered upstream.
114
124
if [[ " $REPO_OWNER " == " opendatahub-io" ]]; then
@@ -136,7 +146,7 @@ if [[ "$REPO_OWNER" == "opendatahub-io" ]]; then
136
146
# Check for latest_tag validity (maybe the new image is not yet build)
137
147
if [[ -z " $latest_tag " || " $latest_tag " == " null" ]]; then
138
148
echo " No matching tag found on registry for $file . Skipping."
139
- # calls log_skipped_image funtion from image-skipping-logger.sh script
149
+ # calls log_skipped_image to log missing updates
140
150
log_skipped_image " $image "
141
151
continue
142
152
fi
@@ -191,7 +201,7 @@ elif [[ "$REPO_OWNER" == "red-hat-data-services" ]]; then
191
201
# Check for latest_tag validity (maybe the new image is not yet built)
192
202
if [[ -z " $latest_tag " || " $latest_tag " == " null" ]]; then
193
203
echo " No matching tag found on registry for $file . Skipping."
194
- # calls log_skipped_image funtion from image-skipping-logger.sh script
204
+ # calls log_skipped_image to log missing updates
195
205
log_skipped_image " $image "
196
206
continue
197
207
fi
0 commit comments