File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -60,19 +60,16 @@ get_openssl_version() {
6060
6161find_runtime_loader () {
6262 runtime_dir=" $1 "
63- # Use the linker bundled with the selected assembly to avoid host/container
64- # shared library drift (e.g. openssl minor updates).
65- loader=$( find " ${runtime_dir} /ld_libs" -maxdepth 1 -name ' ld-linux-*.so*' 2> /dev/null | head -1)
66- if [ -n " $loader " ]; then
67- echo " $loader "
68- return
69- fi
70-
71- loader=$( find " ${runtime_dir} /ld_libs" -maxdepth 1 -name ' ld-musl-*.so.1' 2> /dev/null | head -1)
72- if [ -n " $loader " ]; then
73- echo " $loader "
74- return
75- fi
63+ # Use shell globbing instead of `find` so this works in minimal images
64+ # where findutils may be unavailable.
65+ for loader in " ${runtime_dir} /ld_libs" /ld-linux-* .so* " ${runtime_dir} /ld_libs" /ld-musl-* .so.1; do
66+ if [ -f " $loader " ]; then
67+ echo " $loader "
68+ return 0
69+ fi
70+ done
71+
72+ return 1
7673}
7774
7875run_launcher () {
You can’t perform that action at this time.
0 commit comments