X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=test%2Fcommon%2Fconsul_cbs_functions.sh;h=1b5c8a8e9bd902e5b8b668121e02a6fdfe51322c;hb=00fd1e7bdea32ecef53f99b5e94541350af27504;hp=c783a612f2178954039dacbe86b8c9fb3fab7fbc;hpb=be9a07faf8fbc1030404bbc71f409eb5e19736ba;p=nonrtric.git diff --git a/test/common/consul_cbs_functions.sh b/test/common/consul_cbs_functions.sh index c783a612..1b5c8a8e 100644 --- a/test/common/consul_cbs_functions.sh +++ b/test/common/consul_cbs_functions.sh @@ -43,7 +43,7 @@ __CBS_imagesetup() { # Shall be used for images that does not allow overriding # Both var may contain: 'remote', 'remote-remove' or 'local' __CONSUL_imagepull() { - __check_and_pull_image $2 "$CONSUL_DISPLAY_NAME" $CONSUL_APP_NAME $CONSUL_IMAGE + __check_and_pull_image $2 "$CONSUL_DISPLAY_NAME" $CONSUL_APP_NAME CONSUL_IMAGE } # Pull image from remote repo or use locally built image @@ -52,7 +52,7 @@ __CONSUL_imagepull() { # Shall be used for images that does not allow overriding # Both var may contain: 'remote', 'remote-remove' or 'local' __CBS_imagepull() { - __check_and_pull_image $2 "$CBS_DISPLAY_NAME" $CBS_APP_NAME $CBS_IMAGE + __check_and_pull_image $2 "$CBS_DISPLAY_NAME" $CBS_APP_NAME CBS_IMAGE } # Build image (only for simulator or interfaces stubs owned by the test environment) @@ -70,15 +70,23 @@ __CBS_imagebuild() { } # Generate a string for each included image using the app display name and a docker images format string +# If a custom image repo is used then also the source image from the local repo is listed # arg: __CONSUL_image_data() { echo -e "$CONSUL_DISPLAY_NAME\t$(docker images --format $1 $CONSUL_IMAGE)" >> $2 + if [ ! -z "$CONSUL_IMAGE_SOURCE" ]; then + echo -e "-- source image --\t$(docker images --format $1 $CONSUL_IMAGE_SOURCE)" >> $2 + fi } # Generate a string for each included image using the app display name and a docker images format string +# If a custom image repo is used then also the source image from the local repo is listed # arg: __CBS_image_data() { echo -e "$CBS_DISPLAY_NAME\t$(docker images --format $1 $CBS_IMAGE)" >> $2 + if [ ! -z "$CBS_IMAGE_SOURCE" ]; then + echo -e "-- source image --\t$(docker images --format $1 $CBS_IMAGE_SOURCE)" >> $2 + fi } # Scale kubernetes resources to zero