These file locations are standard locations in our CI setup so be
specific of where to search for them. This prevents the scripts
from picking up data from test files in global-jjb.
Change-Id: Ia486ae8704b77f9303b5a2e54c4ffaf5de41aef8
Signed-off-by: Thanh Ha <thanh.ha@linuxfoundation.org>
declare -a images
declare -a cfg_images
declare -a yaml_images
-readarray -t cfg_images <<< "$(grep -r IMAGE_NAME --include \*.cfg \
+readarray -t cfg_images <<< "$(grep -r IMAGE_NAME --include \*.cfg jenkins-config \
| awk -F'=' '{print $2}' | sort -u)"
-readarray -t yaml_images <<< "$(grep -r 'ZZCI - ' --include \*.yaml \
+readarray -t yaml_images <<< "$(grep -r 'ZZCI - ' --include \*.yaml jjb \
| awk -F": " '{print $3}' | sed "s:'::;s:'$::;/^$/d" | sort -u)"
mapfile -t images < <(for R in "${cfg_images[@]}" "${yaml_images[@]}" ; do echo "$R" ; done | sort -u)