-
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
how to install php-ssh2? #767
Comments
From the Docs on the Docker Hub, you have a couple options: https://github.com/docker-library/docs/tree/b10ac9706270ca71044eb75ccf7158c5124a5a36/php#e-package-php-xxx-has-no-installation-candidate |
Some clues:
I was able to successfully install via the following: FROM php:7.2-cli
RUN set -eux; \
apt-get update; \
apt-get install -y --no-install-recommends libssh2-1-dev; \
pecl install ssh2-1.1.2; \
docker-php-ext-enable ssh2 It's also worth noting that when trying this against PHP 7.3, I get heaps of errors, so PHP 7.3 likely isn't supported by the |
OK thanks for supoort |
|
Doesn't work for me
|
@yi-ge works for php5.4 too, thanks |
I can't install the extension directly. But it works when downloading them manually like this: FROM php:7.4-apache
RUN apt-get update && \
apt-get install -y gcc make libssh2-1-dev libssh2-1
RUN curl http://pecl.php.net/get/ssh2-1.2.tgz -o ssh2.tgz && \
pecl install ssh2 ssh2.tgz && \
docker-php-ext-enable ssh2 && \
rm -rf ssh2.tgz
RUN echo '<?php phpinfo();' > /var/www/html/i.php Navigating to http://127.0.0.1/i.php I see
|
@DMW007 's solution worked for, tried on php7.4-fpm. |
i try install php-ssh2 but get error
apt install php-ssh2
The text was updated successfully, but these errors were encountered: