-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No preferable way to install custom extension that is not mentioned in default list. #77
Comments
+1 got the same problem installing xdebug. |
While we could add a docker-php-pecl-* type script, it wouldn't save you any effort. It's still a simple one liner in your Dockerfile to do it currently. Installing php-redis and xdebug:
If we did make a script, it really would just automate the last portion of my paste above. |
thanks. |
@jaredm4 it might not save much effort, but it would simplify things for users expecting a consistent interface for installing extensions. |
To install xdebug from source, I used this (found this issue later)
|
@jaredm4, thanks for your answer. I'm looking for a way of installing php-redis and I have a few questions. Do I need to install any dependencies before installing redis that way (I use FROM php:fpm)? and do I need to install |
As mentioned on #115, I use my own docker-php-pecl-install script. I like the reduced boilerplate: FROM php:5.6-fpm
COPY docker-php-pecl-install /usr/local/bin/
RUN docker-php-pecl-install xdebug-2.3.3 uploadprogress-1.0.3.1 redis-2.2.5 |
@lazycommit did you install mongo successfully?
mongo.ini:
Doesn't work for me on php:5.6-fpm |
Need a |
@j16sdiz have you tried mine? |
BTW, I installed php-redis extension this way:
I think any other php extension can be installed the same way and without PECL which I don't have by default in ubuntu. Details is here http://stackoverflow.com/a/31623759/202550 |
@ephrin please add that one_line_install_specific_extension_from_pecl_script :) |
Got the same error when I tried this. You finally nailed it @rainbow-alex ? If so: got any hint on how to fix this? |
@roelvanduijnhoven @rainbow-alex More than likely, the folder name changed. Go to /usr/local/lib/php/extensions/ after installing xdebug, take note of the new folder name containing xdebug, and install it like I pasted above (without that custom script). |
Thanks. That solved it. @rainbow-alex If you install xdebug directly on the container it will tell what the filename is. Thus |
Granted, not a good solution as it prevents the Dockerfile from being portable. A pecl install script would be nice, that could determine that path when installing and prevent that issue. |
@rainbow-alex not topical anymore. Pecl installs normally and existent scripts are good as is to enable an extension. **For inspiration look into phpbrew :) |
Add in your
Reference: http://stackoverflow.com/questions/30594804/ |
This doesn't work with php:7.0.1-apache:
I think that xdebug is in some kind of beta right now for PHP7. Correct? |
Looks like it still is just a release candidate:
|
''' |
thank you @ekandreas 👍 |
This works great, thanks @luiscoms
|
Thanks for all the discussion and useful information! I'm closing since there's nothing to change in the image (given that the existing scripts handle this reasonably well), but this thread should serve as a useful reference for folks looking for help doing this kind of thing in the future. 👍 |
I have a project using old mongo extension which is deprecated . Unable to install by pecl. Got a error message "No releases for package "pecl/mongo" exist" when I tried to install mongo extension by running |
1st problem: docker-php-ext-* does not provide a way to install extension package from pecl (for example i need to install ext-mongo which cause me to make some tricks with Dockerfile to succeed)
2nd problem: custom source extensions (e.g. phalcon) that has to be compiled from scratch and exposed to runnin php daemon (fpm, apache).
Is there any instructions to make it right and simple? For any of cases.
Thanks.
The text was updated successfully, but these errors were encountered: