Closed micrology closed 1 year ago
I did pecl install in my CloudFormation EC2 userdata as follows, and is able to install WordPress.
dnf install -q -y php-devel php-pear gcc
pear update-channels
pecl update-channels
dnf install -q -y ImageMagick-devel ImageMagick
/usr/bin/yes 'no' | sudo pecl install -f --configureoptions 'with-imagick="autodetect"' imagick
echo 'extension=imagick.so' > /etc/php.d/25-imagick.ini
systemctl restart php-fpm
Edit: Seems that PECL install does not work with PHP 8.3, please refer to re:Post article How do I compile PHP extensions on Amazon Linux 2023?
Edit : run the above commands as root
Thanks - that seems to work. Some caveats:
sudo
)/etc/php.d/20-imagick.ini
containing the one line extension=imagick
sudo systemctl restart php-fpm
It isn’t provided – you have to create it yourself (this, and what to put in it, is explained in my comment to the Package request).
Nigel Gilbert Lead developer, PRSMhttps://prsm.uk/ @.***
From: Jeff @.> Date: Friday, 6 October 2023 at 15:31 To: amazonlinux/amazon-linux-2023 @.> Cc: Gilbert, Nigel Prof (Sociology) @.>, State change @.> Subject: Re: [amazonlinux/amazon-linux-2023] [Package Request] - Include php-pecl-imagick (Issue #466) · 20-imagick.ini
Where'd you get this file in the first place? I've installed ImageMagick-devel and ImageMagick, but I'm not sure where they we're installed, and I can't seem to find 20-imagick.ini anywhere in my server.
— Reply to this email directly, view it on GitHubhttps://github.com/amazonlinux/amazon-linux-2023/issues/466#issuecomment-1750782153, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AALCAAUS7Y55OEXYSZENCRDX6AI5XAVCNFSM6AAAAAA5EMNWJ2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTONJQG44DEMJVGM. You are receiving this because you modified the open/close state.Message ID: @.***>
I see the issue is closed but was there a resolution on this? Can I add the packages to .ebextensions/install_dependancies.config
? What are they called? Thanks!
@limmike Are these two lines not duplicates? The second just performing autoanswer to prompts?
pecl install --configureoptions 'with-imagick="autodetect"' imagick
/usr/bin/yes 'no' | sudo pecl install -f --configureoptions 'with-imagick="autodetect"' imagick
But thanks for the solution. Very helpful!
@limmike Are these two lines not duplicates? The second just performing autoanswer to prompts?
pecl install --configureoptions 'with-imagick="autodetect"' imagick
/usr/bin/yes 'no' | sudo pecl install -f --configureoptions 'with-imagick="autodetect"' imagick
But thanks for the solution. Very helpful!
@rwhirn good catch! updated
btw, PECL install for PHP 8.3 does not work for me. You can refer to my re:Post article How do I compile PHP extensions on Amazon Linux 2023? for Imagick and other extensions.
What package is missing from Amazon Linux 2023? Please describe and include package name.
php-pecl-imagick
It provides a wrapper to the ImageMagick library URL : https://pecl.php.net/package/imagick Description : Imagick is a native php extension to create and modify images using the ImageMagick API.Is this an update to existing package or new package request? New request
Is this package available in Amazon Linux 2? If it is available via external sources such as EPEL, please specify.
Yes, and from the Fedora distribution
Any additional information you'd like to include. (use-cases, etc)
It provides a PHP module that is highly recommended for a WordPress installation, as well as providing a host of image manipulation facilities.