Files
containers/.vib/common/goss/scripts/check-linked-libraries.sh
Carlos Rodríguez Hernández 45d7897631 [bitnami/*] Set new header/owner (#66218)
Signed-off-by: Carlos Rodríguez Hernández <carlosrh@vmware.com>
2024-05-06 15:06:33 +02:00

17 lines
447 B
Bash
Executable File

#!/bin/bash
# Copyright Broadcom, Inc. All Rights Reserved.
# SPDX-License-Identifier: APACHE-2.0
set -o errexit
set -o nounset
set -o pipefail
mapfile -t files < <( find "$BITNAMI_ROOT_DIR"/"$BITNAMI_APP_NAME" "$BITNAMI_ROOT_DIR"/common -type f -executable )
for file in "${files[@]}"; do
if [[ -n $EXCLUDE_PATHS ]] && [[ "$file" =~ $EXCLUDE_PATHS ]]; then
continue
fi
[[ $(ldd "$file" | grep -c "not found") -eq 0 ]] || exit 1
done