PHP Repository Installation

1

Hi, I’m using Amazon Linux 2023 with LEMP installed for WordPress. and I’ve using NginX’s and MariaDB’s official repositories. Since there’s no official php repo, so I used the Amazon Linux 2023 repository, but its php package doesn’t have the php module imagick recommended by WP.

It’s been stated Amazon Linux 2023 doesn’t support EPEL, so is there any way to install imagick?

Thanks!

gefragt vor 10 Monaten936 Aufrufe
1 Antwort
0
Akzeptierte Antwort

As you are aware, php-pecl-imagick has been removed in Amazon Linux 2023.
Also, the EPEL repository cannot be used.
https://docs.aws.amazon.com/ja_jp/linux/al2022/release-notes/removed-packages.html

So follow the steps below to add the Fedora 36 repository.

sudo vi /etc/yum.repos.d/fedora.repo

[fedora]
name=Fedora 36 - $basearch
#baseurl=http://download.example/pub/fedora/linux/releases/36/Everything/$basearch/os/
metalink=https://mirrors.fedoraproject.org/metalink?repo=fedora-36&arch=$basearch
enabled=0
countme=1
metadata_expire=7d
repo_gpgcheck=0
type=rpm
gpgcheck=1
gpgkey=https://getfedora.org/static/fedora.gpg
skip_if_unavailable=False

After adding the repository, you can install it with the following command.

sudo dnf --enablerepo=fedora install php-pecl-imagick -y
profile picture
EXPERTE
beantwortet vor 10 Monaten
profile pictureAWS
EXPERTE
überprüft vor 10 Monaten
  • How to add Fedora 38 repo? Because Fedora 36 is deprecated and no longer maintained or updated.

  • I just tried the following settings and was able to install even on Fedora 38.

    [fedora]
    name=Fedora 38 - $basearch
    #baseurl=http://download.example/pub/fedora/linux/releases/36/Everything/$basearch/os/
    metalink=https://mirrors.fedoraproject.org/metalink?repo=fedora-38&arch=$basearch
    enabled=0
    countme=1
    metadata_expire=7d
    repo_gpgcheck=0
    type=rpm
    gpgcheck=1
    gpgkey=https://getfedora.org/static/fedora.gpg
    skip_if_unavailable=False
    
    sudo dnf --enablerepo=fedora install php-pecl-imagick -y
    sudo dnf --enablerepo=fedora info php-pecl-imagick
    Last metadata expiration check: 0:02:22 ago on Thu Jul 20 02:44:29 2023.
    Installed Packages
    Name         : php-pecl-imagick
    Version      : 3.7.0
    Release      : 6.fc38
    Architecture : x86_64
    Size         : 1.1 M
    Source       : php-pecl-imagick-3.7.0-6.fc38.src.rpm
    Repository   : @System
    From repo    : fedora
    Summary      : Provides a wrapper to the ImageMagick library
    URL          : https://pecl.php.net/package/imagick
    License      : PHP
    Description  : Imagick is a native php extension to create and modify images using the
                 : ImageMagick API.
    

    Just to share for the record, Amazon Linux 2023 is created on a Fedora 34-36 base. In other words, please note that in some cases it may occur that the intended behavior may not be achieved. https://docs.aws.amazon.com/ja_jp/linux/al2023/ug/relationship-to-fedora.html

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen