3 # Copyright (c) 2020 Cisco and/or its affiliates.
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at:
8 # http://www.apache.org/licenses/LICENSE-2.0
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
18 export CIMAN_DOCKER_SCRIPTS=${CIMAN_DOCKER_SCRIPTS:-"$(dirname $BASH_SOURCE)"}
19 export CIMAN_ROOT=${CIMAN_ROOT:-"$(dirname $(dirname $CIMAN_DOCKER_SCRIPTS))"}
20 . $CIMAN_DOCKER_SCRIPTS/lib_common.sh
23 must_be_run_in_docker_build
27 grep -q e <<< $set_opts && set +e # disable exit on errors
30 local found="$(grep -nisH error $DOCKER_BUILD_LOG_DIR/*-bld.log)"
31 if [ -n "$found" ] ; then
32 echo -e "\nErrors found in build log files:\n$found\n"
34 echo -e "\nNo errors found in build logs\n"
38 found="$(grep -nisH warning $DOCKER_BUILD_LOG_DIR/*-bld.log)"
39 if [ -n "$found" ] ; then
40 echo -e "\nWarnings found in build log files:\n$found\n"
42 echo -e "\nNo warnings found in build logs\n"
45 grep -q e <<< $set_opts && set -e # re-enable exit on errors
49 local cache_files_log="$DOCKER_BUILD_LOG_DIR/cached_files.json"
50 tree -a --timefmt "+%Y-%m-%d %H:%M:%S" --prune /root
51 tree -afJ --timefmt "+%Y-%m-%d %H:%M:%S" --prune -o $cache_files_log /root