PECL

docker php-fpm 拓展安装

為{幸葍}努か 提交于 2019-12-04 16:57:27
1. PHP 源码 为了保证 Docker 镜像尽量小,PHP 的源文件是以压缩包的形式存在镜像中,官方提供了 docker-php-source 快捷脚本,用于对源文件压缩包的解压(extract)及解压后的文件进行删除(delete)的操作。 示例: FROM php:7.1-apache RUN docker-php-source extract \ # 此处开始执行你需要的操作 \ && docker-php-source delete 注意:一定要记得删除,否则解压出来的文件会大大增加镜像的文件大小。 2. 安装扩展 2.1. 核心扩展 这里主要用到的是官方提供的 docker-php-ext-configure 和 docker-php-ext-install 快捷脚本,如下 FROM php:7.1-fpm RUN apt-get update \ # 相关依赖必须手动安装 && apt-get install -y \ libfreetype6-dev \ libjpeg62-turbo-dev \ libmcrypt-dev \ libpng-dev \ # 安装扩展 && docker-php-ext-install -j$(nproc) iconv mcrypt \ # 如果安装的扩展需要自定义配置时 && docker-php-ext-configure

pecl:command not found

和自甴很熟 提交于 2019-12-04 16:20:53
问题 I'm trying to run the following command in terminal on my macbook pro cd /tmp; pecl download memcached but im getting pecl:command not found. after a days googling I cant find out whats up. Does anyone have a solution? 回答1: At least on Arch Linux you must install php-pear package for the pecl tool by using this command: pacman -S php-pear 回答2: apt-get update apt-get install php-pear php5-dev 回答3: I know, old post but for anyone else. On Windows PECL and PEAR commands are not found but they

Installing Solr in a XAMPP server in a LINUX server

冷暖自知 提交于 2019-12-04 15:52:49
I try to install Solr PHP extension to my webserver. I already have an XAMPP server and I'm using PECL to install solr $ cd /opt/lampp/bin $ sudo ./pecl install solr-1.0.1 But I got the following error: checking libxml2 install dir... /usr/lib checking for xml2-config path... configure: error: xml2-config not found. Please check your libxml2 installation. ERROR: `/tmp/pear/temp/solr/configure --enable-solr=yes --enable-solr-debug=no --with-curl= /usr --with-libxml-dir=/usr/lib' failed During the installation it prompts me to input a path: libxml2 install prefix [/usr] : I have tried with enter

Why are there no longer Windows binaries for PECL extensions like pecl_http?

守給你的承諾、 提交于 2019-12-04 11:04:20
问题 I'm working on a PHP project running on Windows and it would be so very handy to be able to use pecl_http rather than working with cURL and re-inventing the wheel in order to do all the cool stuff the pecl extension does like parsing headers and so forth. Everywhere I read (including the PHP site) is that the Windows binary for pecl_http is no longer packaged with any PHP installation. I can't find any explanation as to why not anywhere. Also, http://pecl4win.php.net/ has been down for ages

Installing pecl_http in xubuntu

旧时模样 提交于 2019-12-04 08:35:22
问题 As per title, I am simply trying to install pecl_http extension for php in ubuntu. So I did what makes most sense: andreas@earl ~ $ sudo pecl install pecl_http downloading pecl_http-1.6.6.tgz ... Starting to download pecl_http-1.6.6.tgz (173,645 bytes) .....................................done: 173,645 bytes 71 source files, building running: phpize Configuring for: PHP Api Version: 20041225 Zend Module Api No: 20060613 Zend Extension Api No: 220060519 1. whether to enable cURL HTTP requests;

struggling to install PHP pecl on Centos

心已入冬 提交于 2019-12-04 08:05:45
问题 I'm trying to install the php_http PHP extension on my CentOS server. I have done: yum install php-pear But get: No package php-pear available Yet I can do: pear And get a list of commands from Pear. Same for yum install pecl . I can do pecl but pecl install pecl_http returns: No releases available for package "pecl.php.net/pecl_http" install failed Yet /usr/bin/pecl isn't a directory that exists. Also a sudo pecl install pecl_http returns sudo: pecl: command not found , which I find quite

How to install php extension using pecl for specific php version, when several php versions installed in system?

妖精的绣舞 提交于 2019-12-04 07:48:28
问题 I have installed both php5.6 and php7.0 from PPA on Ubuntu according to this manual http://lornajane.net/posts/2016/php-7-0-and-5-6-on-ubuntu But I didn't get how to install extensions using pecl for php5.6 or php7.0. For example I have already installed version of libevent or amqp in php5.6. Now when I type pecl install libevent and my active php version is php7.0 (using update-alternatives --set php /usr/bin/php7.0), pecl returns message that libevent` already installed. But it was

CentOS下yum安装PHP,配置php-fpm服务

China☆狼群 提交于 2019-12-04 06:16:01
yum list installed | grep php 先删除已有的php版本 ,执行下面的命令删除php yum remove php-common 然后像安装那样问你是否继续的,输入yes即可 添加 yum 源 CentOS 6.x 的源 # rpm -Uvh http://download. Fedora project.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm # rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm CentOS 7.x 的源 # rpm -Uvh http://ftp.iij.ad.jp/pub/linux/fedora/epel/7/x86_64/e/epel-release-7-5.noarch.rpm # rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-7.rpm 安装 PHP # yum install --enablerepo=remi,remi-php56 php php-opcache php-pecl-apcu php-devel php-mbstring php-mcrypt php-mysqlnd php

PHP ssh2_exec channel exit status?

独自空忆成欢 提交于 2019-12-04 05:25:22
Ok, so pecl ssh2 is supposedly a wrapper for libssh2. libssh2 has libssh2_channel_get_exit_status. Is there ANY way to get this information? I NEED: -STDOUT -STDERR -EXIT STATUS I get all but exit status. A lot of people throw around phplibsec when ssh is brought up, but I see no way of getting stderr or the channel exit status out of that either:/ Has anybody been able to get all three? So, first thing is first: NO, they didn't implement libssh2_channel_get_exit_status. Why? Beyond me. Here is what id did: $command .= ';echo -e "\n$?"' I cram a newline and echo of $? onto the end of every

PHP mailparse.so error - undefined symbol mbfl_convert_filter_flush

戏子无情 提交于 2019-12-04 02:45:55
sudo pecl install mailparse ends with: Build process completed successfully Installing '/usr/lib64/php/5.5/modules/mailparse.so' install ok: channel://pecl.php.net/mailparse-2.1.6 configuration option "php_ini" is not set to php.ini location You should add "extension=mailparse.so" to php.ini After adding extension=mailparse.so to the Dynamic Extensions section of php.ini , running php prints this: PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/5.5/modules/mailparse.so' - /usr/lib64/php/5.5/modules/mailparse.so: undefined symbol: mbfl_convert_filter_flush in Unknown on