Merge pull request #419 from mlocati/blackfire

Improve blackfire installation
pull/421/head 1.2.55
Michele Locati 2021-08-12 18:05:11 +02:00 committed by GitHub
commit 124c35a9d8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 9 additions and 12 deletions

View File

@ -1657,24 +1657,21 @@ installRemoteModule() {
blackfire) blackfire)
case $(uname -m) in case $(uname -m) in
i386 | i686 | x86) i386 | i686 | x86)
architecture="i386" installRemoteModule_tmp1=i386
;;
x86_64 | amd64)
architecture="amd64"
;; ;;
aarch64 | arm64 | armv8) aarch64 | arm64 | armv8)
architecture="arm64" installRemoteModule_tmp1=arm64
;; ;;
*) *)
architecture="amd64" installRemoteModule_tmp1=amd64
;; ;;
esac esac
version=$(php -r "echo PHP_MAJOR_VERSION.PHP_MINOR_VERSION;") installRemoteModule_tmp2=$(php -r 'echo PHP_MAJOR_VERSION . PHP_MINOR_VERSION;')
curl -A "Docker" -o /tmp/blackfire-probe.tar.gz -D - -L -s https://blackfire.io/api/v1/releases/probe/php/linux/$architecture/$version installRemoteModule_tmp="$(mktemp -p /tmp/src -d)"
mkdir -p /tmp/blackfire cd "$installRemoteModule_tmp"
tar zxpf /tmp/blackfire-probe.tar.gz -C /tmp/blackfire curl -sSLf --user-agent Docker https://blackfire.io/api/v1/releases/probe/php/linux/$installRemoteModule_tmp1/$installRemoteModule_tmp2 | tar xz
mv /tmp/blackfire/blackfire-*.so $(getPHPExtensionsDir)/blackfire.so mv blackfire-*.so $(getPHPExtensionsDir)/blackfire.so
rm -rf /tmp/blackfire /tmp/blackfire-probe.tar.gz cd - >/dev/null
installRemoteModule_manuallyInstalled=1 installRemoteModule_manuallyInstalled=1
;; ;;
cmark) cmark)