From 7e51682eb925643a09f5c6940c15f989c84e1eb2 Mon Sep 17 00:00:00 2001 From: dsech Date: Wed, 18 Aug 2021 16:51:58 +0300 Subject: [PATCH] Install the correct version of blackfire on alpine Test: blackfire --- install-php-extensions | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/install-php-extensions b/install-php-extensions index 9f4e474..fec98f1 100755 --- a/install-php-extensions +++ b/install-php-extensions @@ -1666,10 +1666,18 @@ installRemoteModule() { installRemoteModule_tmp1=amd64 ;; esac + case $DISTRO in + alpine) + installRemoteModule_distro=alpine + ;; + *) + installRemoteModule_distro=linux + ;; + esac installRemoteModule_tmp2=$(php -r 'echo PHP_MAJOR_VERSION . PHP_MINOR_VERSION;') installRemoteModule_tmp="$(mktemp -p /tmp/src -d)" 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 cd - >/dev/null installRemoteModule_manuallyInstalled=1