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

Add Imagick extension #223

Open
fifle opened this issue Mar 31, 2022 · 5 comments
Open

Add Imagick extension #223

fifle opened this issue Mar 31, 2022 · 5 comments

Comments

@fifle
Copy link

fifle commented Mar 31, 2022

Feature Request

It looks like Imagick extension is missing for now. I'm using a library for generating QR-code in my Laravel application and it requires the support of Imagick for generating QR-code images in PNG format (I also need it for user to be downloadable, so it's really needed).

It looks like it's a tiny extension and won't bring troubles with issues with lambda.
http://pecl.php.net/package/imagick

@testliopavel
Copy link

Hi @f3l1x ! Is there any chance to get this update for upcoming releases? Heroku is closing it's free tier soon and I'm looking forward for moving to Vercel this month. So maybe, it will be possible due to adding Imagick extension into your runtime :)

@f3l1x
Copy link
Collaborator

f3l1x commented Oct 1, 2022

Hi @testliopavel, I will take a look. I hope imagick will be not 20 MB binary :-D

@f3l1x
Copy link
Collaborator

f3l1x commented Oct 1, 2022

There is a little problem with imagick on AmazonLinux 2 with Remi's RPM repository (https://blog.remirepo.net/pages/PECL-extensions-RPM-status).

#10 23.50 --> Processing Dependency: libraw_r.so.19()(64bit) for package: ImageMagick6-libs-6.9.12.64-1.el7.remi.x86_64
#10 23.50 ---> Package libpciaccess.x86_64 0:0.14-1.amzn2 will be installed
#10 23.50 --> Processing Dependency: hwdata for package: libpciaccess-0.14-1.amzn2.x86_64
#10 23.50 --> Running transaction check
#10 23.50 ---> Package ImageMagick6-libs.x86_64 0:6.9.12.64-1.el7.remi will be installed
#10 23.51 --> Processing Dependency: libraw_r.so.19()(64bit) for package: ImageMagick6-libs-6.9.12.64-1.el7.remi.x86_64
#10 23.51 ---> Package hwdata.x86_64 0:0.252-9.3.amzn2 will be installed
#10 23.54 --> Finished Dependency Resolution
#10 23.61 Error: Package: ImageMagick6-libs-6.9.12.64-1.el7.remi.x86_64 (remi)
#10 23.61            Requires: libraw_r.so.19()(64bit)
#10 23.61  You could try using --skip-broken to work around the problem
#10 23.66  You could try running: rpm -Va --nofiles --nodigest

According to Bref (alternative tool for serverless PHP), there is so much dependencies for Imagick extension. Vercel Serverless Functions have hard limit of 50Mb. In this case we'd need to use another AWS lambda layer.

https://github.com/brefphp/extra-php-extensions/blob/105f25ab3cdc12188ca031cef4205ff033d16b83/layers/imagick/Dockerfile#L70-L109

Anyway, I am still investigating how to do it. But I have no ETA at this moment.

@tao
Copy link

tao commented Nov 12, 2024

I've been using Imagick to generate thumbnails so maybe this issue has resolved itself with time.

@f3l1x
Copy link
Collaborator

f3l1x commented Nov 13, 2024

Hi @tao, can you share little sneak peak how you use it?

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

No branches or pull requests

4 participants