error usr src php ext mcrypt does not exist

Memcached support #132

Comments

polds commented Sep 14, 2015

Wondering if anyone has gotten memcached (not memcache) to work? Trying to build in php:5.5.29-apache to get the php memcached module installed. I have tried the following to no avail. Any help is greatly appreciated.

Dockerfile 1

Notes:

Dockerfile 2

Notes:

Dockerfile 3

Notes:

The text was updated successfully, but these errors were encountered:

We are unable to convert the task to an issue at this time. Please try again.

The issue was successfully created but we are unable to update the comment at this time.

md5 commented Sep 14, 2015

@polds I think you want to use «Dockerfile 2», but you need to install libz-dev to make configure happy.

md5 commented Sep 14, 2015

Actually, nevermind. I thought you were using docker-php-ext-install 😕

You need something like this:

polds commented Sep 14, 2015

@md5 thank you that was indeed it with the following modification (for future readers):

md5 commented Sep 14, 2015

That reminds me that @helderco once mentioned creating a docker-php-pecl-install script: #115 (comment)

hairmare commented Sep 14, 2015

The smallest layer for the pecl install is probably the following:

polds commented Sep 14, 2015

^ That worked as well.

md5 commented Sep 14, 2015

Thanks @hairmare I was being lazy since I don’t tend to be as aggressive with the sizes of «normal» images.

roelvanduijnhoven commented Jan 6, 2016

I failed to get memcached to work on PHP7. Finally managed to do so using the following lines, using the php7 branch and building from source:

Is there any better way?

paolomainardi commented Jan 12, 2016

roelvanduijnhoven commented Jan 12, 2016

Thanks @paolomainardi, looks a lot easier. I realise now how the bundled docker-php-ext.. scripts work.

paolomainardi commented Jan 12, 2016

skyred commented Jan 25, 2016

Thank you all. I further shortened #132 (comment) a little bit. Now, I am using this config in my image for Drupal https://github.com/INsReady/php-fpm-for-cms/blob/master/7.0/Dockerfile#L11

vitalyzhakov commented Jul 27, 2016

With last version php:7.0-fpm stop working

yosifkit commented Jul 27, 2016

@vitalyzhakov, I think that is related to #266.

roelvanduijnhoven commented Aug 1, 2016

Did anyone manage to fix this problem? I am reading through #266 but have no clue if and how I should solve this..

vitalyzhakov commented Aug 1, 2016 •

This code works for me under php 7.0.8-fpm

roelvanduijnhoven commented Aug 2, 2016

rasteiner commented Aug 9, 2016

This may be obvious, but for someone (like me) it’s not.

Something like this works for me:

c0deright commented Sep 9, 2016

Please do it the right way: use the docker-php-* scripts and cleanup afterwards.

The best practice should look something like this:

bscheshir commented Oct 13, 2016 •

@adminblogger nice! Thx!

Читайте также:  Virtualalloc remapping failed что это за ошибка

jordanlgraham commented Feb 20, 2017 •

For anyone who finds this because their Dockerfile has begun to fail while trying «pecl install memcached» (with the error «pecl/memcached requires PHP (version >= 7.0.0), installed version is [5.6.something]», on 02/08/17 the pecl memcached package version 3.0 was released, requiring php 7.0 or higher.

To continue using memcached with php 5.6.x, update your Dockerfile to use version 2.2.0 of the memcached package:

pecl install memcached-2.2.0

pecl install memcached

The relevant section of my Dockerfile, as a result, is:

Источник

Как исправить ошибку сборки Docker «/usr/src/php/ext/mcrypt не существует»?

Я пытаюсь установить mcrypt в свой образ docker на основе php:7.2-apache. Поэтому я использую команду RUN-Command из документации, а также отвечаю здесь, но получаю эту ошибку. Я думаю, может быть, в то время как установка может отсутствовать.

Это мой файл app.docker.

сообщите об ошибке в when build docker.

Несмотря на то, что путь к нему указан в Dockerfile, он говорит, что не найден

Кто-нибудь знает почему?

2 ответа

Это связано с тем, что mcrypt устарел после php:7.1. Вы можете использовать базовый образ, который все еще поддерживает mcrypt, например php:5.6-cli, или использовать альтернативу mcrypt.

Это сработало для меня, скопировано отсюда :

Похожие вопросы:

Я недавно начал использовать docker и смог настроить два контейнера, один работает php7.0 с apache2, а другой работает mysql, оба они могут разговаривать друг с другом, и все работает нормально.

Я пытаюсь установить nginx+php-fpm с Laravel через docker на AWS Elastic Beanstalk. Я смог успешно запустить его и запустить, однако Laravel выдает мне ошибку: Mcrypt PHP extension required. Я смог.

Я хотел бы развернуть свой проект Laravel с GitLabCI и docker. У меня есть файл yaml со следующим before_script : docker-php-ext-install mbstring mcrypt pdo_mysql curl json intl gd xml zip bz2.

Я пытаюсь настроить конвейеры с Bitbucket для одного из управляемых проектов Laravel и уже потратил несколько часов, пытаясь заставить его работать, но просто не могу справиться со следующим: +.

Попытка создать образ (из рабочего) Я получил эту ошибку, искал решение в Google, но не смог найти подходящее, я предполагаю, что что-то не так с библиотеками. Не совсем понимаю, что означает Error.

Источник

Deploy Laravel with GitlabCI failed on mcrypt extension #531

Comments

polaroi8d commented Dec 5, 2017

I would like to deploy my project on Gitlab CI with a yaml file. Dumped the following error log when I tried to install php extensions.

I tried to add apt-get install mcrypt php7.0-mcrypt but nothing happend. Anyone has a suggestion?

The text was updated successfully, but these errors were encountered:

We are unable to convert the task to an issue at this time. Please try again.

The issue was successfully created but we are unable to update the comment at this time.

Читайте также:  Что хотят то и воротят

bweston92 commented Dec 5, 2017

Hi @polaroi8d can you provide the base image name you’re using?

polaroi8d commented Dec 5, 2017

Hello @bweston92 I am always using the latest image from https://hub.docker.com/r/library/php/ with the command of image: php:latest

bweston92 commented Dec 5, 2017

polaroi8d commented Dec 5, 2017

Ohhh, I don’t know it. What is the last version of php where mcrypt is supported? @bweston92

bweston92 commented Dec 5, 2017

polaroi8d commented Dec 5, 2017

Thanks for the help @bweston92 I am really appreciate for your help

thomasvargiu commented Dec 5, 2017

In PHP 7.2 you can install mcrypt via PECL

geneowak commented Jan 25, 2019

In PHP 7.2 you can install mcrypt via PECL

And how do you add it in the php.ini or to the image?

Build process completed successfully Installing ‘/usr/local/lib/php/extensions/no-debug-non-zts-20170718/mcrypt.so’ install ok: channel://pecl.php.net/mcrypt-1.0.1 configuration option «php_ini» is not set to php.ini location You should add «extension=mcrypt.so» to php.ini

geneowak commented Jan 25, 2019

Turns out I didn’t have to update the php.ini file. I removed mcrypt from docker-php-ext-install
and just added these lines

and it run without giving me an error. I was creating an image to run a Laravel 5.7 application (which I think still needs mcrypt) using the CI of gitlab. The image was created successfully and the tests run well.

Источник

php7.2 not contatin mcrypt extension #1148

Comments

bscheshirwork commented Jul 14, 2017 •

Because mcrypt is deprecated

The text was updated successfully, but these errors were encountered:

We are unable to convert the task to an issue at this time. Please try again.

The issue was successfully created but we are unable to update the comment at this time.

terrafrost commented Jul 14, 2017 •

Can you provide the code that gives you that error?

Removing mcrypt is not going to happen because, deprecated tho it may be, it’s still a heck of a lot faster than the pure-PHP implementation. The fact that it’s being used on your system suggests that OpenSSL isn’t available so mcrypt is gonna be the fastest way to do encryption in PHP.

terrafrost commented Jul 14, 2017

It doesn’t look like Travis CI even supports PHP 7.2 yet:

zoispag commented Jul 28, 2017

@terrafrost will it work for PHP 7.2, when mcrypt will be completely removed?

terrafrost commented Jul 31, 2017 •

For the past few years, even with 5.6, finding systems with mcrypt even installed is rare. The PHP that apt-get installed on Ubuntu hasn’t had it in years. At least not by default. So, to answer your question. yes, it should work, because if running phpseclib without mcrypt didn’t work we’d have heard about it by now.

Читайте также:  Что такое эфес сабли

Источник

Error Usr Src Php Ext Mcrypt Does Not Exist

We have collected for you the most relevant information on Error Usr Src Php Ext Mcrypt Does Not Exist, as well as possible solutions to this problem. Take a look at the links provided and find the solution that works. Other people have encountered Error Usr Src Php Ext Mcrypt Does Not Exist before you, so use the ready-made solutions.

    https://askubuntu.com/questions/1031921/php-mcrypt-package-missing-in-ubuntu-server-18-04-lts
    Done Package php-mcrypt is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source E: Package ‘php-mcrypt’ has no installation candidate apt server package-management apache2 php
    https://forums.cpanel.net/threads/mcrypt-php-extension.617031/
    Jul 09, 2018 · Hi, The PHP developers deprecated mcrypt in version 7.1, and removed support in version 7.2. Applications should use either sodium or openssl for encryption needs.

Docker-php-ext-install mcrypt carpeta que falta RePHP

    https://gist.github.com/arzzen/1209aa4a430bd95db3090a3399e6c35f
    Dec 15, 2020 · I found that the lastest version of PHP which cames with these Dll´s (‘libmcrypt.dll’ and ‘/ext/php_mcrypt.dll’) is php-5.2.9-Win32-VC6-x86.zip

How to install mcrypt in php7.2 / php7.3 LukáЕЎ MeЕЎЕҐan

    https://lukasmestan.com/install-mcrypt-extension-in-php7-2/
    Dec 20, 2017 · The mcrypt extension is an interface to the mcrypt cryptography library. This extension is useful for allowing PHP code using mcrypt to run on PHP 7.2+.. The main problem with mcrypt extension is that it is based on libmcrypt that hasn’t been developped since its upstream in 2007. Thus, it has been already 10 years, even though the library has been still used.
    https://www.php.net/manual/en/book.mcrypt.php
    I just wanted to confirm that we suffered massive performance issues related to mcrypt on CentOS (PHP 5.6.32) that are not present in other flavors of Linux. A sampling of 25,000 encrypts/decrypts takes 4-5x longer when running mcrypt on Centos 7 as compared to Ubuntu.
    https://talk.plesk.com/threads/install-php7-3-7-4-mcrypt-debian.358966/
    Dec 03, 2020 · L’erreur suivante est survenue lors de l’installation de l’application : L’installation de magento sous https://welovewine.tk/ a échoué. Non-zero exit status returned by script.
    https://stackoverflow.com/questions/47181369/how-to-install-mcrypt-on-docker
    From PHP manual: This extension has been moved to the » PECL repository and is no longer bundled with PHP as of PHP 7.2.0. So in your Dockerfile you have to: RUN apt-get install libmcrypt-dev RUN pecl install mcrypt-1.0.1 && docker-php-ext-enable mcrypt

Error Usr Src Php Ext Mcrypt Does Not Exist Fixes & Solutions

We are confident that the above descriptions of Error Usr Src Php Ext Mcrypt Does Not Exist and how to fix it will be useful to you. If you have another solution to Error Usr Src Php Ext Mcrypt Does Not Exist or some notes on the existing ways to solve it, then please drop us an email.

Источник

Образовательный портал