Skip to content
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

Upgrade to 2.4.7 - Undefined constant FTP_BINARY #1147

Open
ClemenF opened this issue May 1, 2024 · 3 comments
Open

Upgrade to 2.4.7 - Undefined constant FTP_BINARY #1147

ClemenF opened this issue May 1, 2024 · 3 comments

Comments

@ClemenF
Copy link

ClemenF commented May 1, 2024

Description
I am upgrading my Magento EE from 2.4.5 to 2.4.7.
I used the image markoshust/magento-php:8.1-fpm and changed it to markoshust/magento-php:8.2-fpm-4.

I got the following Exception when editing a scheduled import from BO :
Undefined constant "Magento\ScheduledImportExport\Model\Scheduled\Operation\FTP_BINARY"

It seems to be a constant defined with the extension php-ftp. It was present in my old application settings :
(screenshot in PHP fpm docker, result of PHP --m)
image

With the new version, the extension isn't present anymore.

Is it normal to don't have it anymore?

Thanks!

@Kevin9131
Copy link

Same issue here on Magento 2.4.6-p3 and 8.2-fpm, 8.2-fpm-4

@ClemenF
Copy link
Author

ClemenF commented May 7, 2024

docker-library/php#1488
php remove the ftp extension. Could it be added to the image?

@zfaty
Copy link

zfaty commented Jun 13, 2024

You need to install the FTP extension
to do that you can customize the php markoshust/magento-php:8.2-fpm-1 image .

Add a new Dockerfile that extend from the image
path => images/php/Dockerfile

Dockerfile:

FROM markoshust/magento-php:8.2-fpm-1

USER root

RUN apt-get install -y libssl-dev

RUN docker-php-ext-configure ftp --with-openssl-dir=/usr \
	&& docker-php-ext-install ftp
	
USER app

then go the compose.yaml to update the phpfpm service
Replace image: markoshust/magento-php:8.2-fpm-1 by your local image => build: images/php
so the service will be something like:


  phpfpm:
    build: images/php
    volumes: *appvolumes
    env_file: env/phpfpm.env

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants