Install ImageMagick and php-ImageMagick on centos8
First, install epel-release
dnf install -y epel-release
install ImageMagick
dnf install -y ImageMagick ImageMagick-devel
Install php and php-pear, compile tools
dnf install -y php php-devel php-pear make
Now, install PHP Imagick with pecl command.
pecl install imagick
Add php extention configuration
echo "extension=imagick.so" > /etc/php.d/20-imagick.ini
For wordpress installation, restart php-fpm
systemctl restart php-fpm
Confirm extention is loaded
php -m
[PHP Modules]
calendar
Core
...
iconv
imagick
...