Merge pull request #421 from dsech/fix-alpine-blackfire

Install the correct version of blackfire on alpine
pull/423/head 1.2.57
Michele Locati 2021-08-19 11:26:54 +02:00 committed by GitHub
commit edf2c4d40d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 9 additions and 1 deletions

View File

@ -1666,10 +1666,18 @@ installRemoteModule() {
installRemoteModule_tmp1=amd64 installRemoteModule_tmp1=amd64
;; ;;
esac esac
case $DISTRO in
alpine)
installRemoteModule_distro=alpine
;;
*)
installRemoteModule_distro=linux
;;
esac
installRemoteModule_tmp2=$(php -r 'echo PHP_MAJOR_VERSION . PHP_MINOR_VERSION;') installRemoteModule_tmp2=$(php -r 'echo PHP_MAJOR_VERSION . PHP_MINOR_VERSION;')
installRemoteModule_tmp="$(mktemp -p /tmp/src -d)" installRemoteModule_tmp="$(mktemp -p /tmp/src -d)"
cd "$installRemoteModule_tmp" cd "$installRemoteModule_tmp"
curl -sSLf --user-agent Docker https://blackfire.io/api/v1/releases/probe/php/linux/$installRemoteModule_tmp1/$installRemoteModule_tmp2 | tar xz curl -sSLf --user-agent Docker https://blackfire.io/api/v1/releases/probe/php/$installRemoteModule_distro/$installRemoteModule_tmp1/$installRemoteModule_tmp2 | tar xz
mv blackfire-*.so $(getPHPExtensionsDir)/blackfire.so mv blackfire-*.so $(getPHPExtensionsDir)/blackfire.so
cd - >/dev/null cd - >/dev/null
installRemoteModule_manuallyInstalled=1 installRemoteModule_manuallyInstalled=1