ImageMagick和webp格式


10:00:08 site1.1     | ActionView::Template::Error (`convert /tmp/ActiveStorage-376-20211007-8992-1phxckm.png[0] -auto-orient -resize 250x250^ -sharpen 0x1 -gravity Center -background rgba(255,255,255,0.0) -extent 250x250 /tmp/image_processing20211007-8992-1lsau5b.png` failed with error:
10:00:08 site1.1     | convert-im6.q16: delegate failed `'dwebp' -pam '%i' -o '%o'' @ error/delegate.c/InvokeDelegate/1919.
10:00:08 site1.1     | convert-im6.q16: unable to open file `/tmp/magick-9861NaGl0bRdSNrq': No such file or directory @ error/constitute.c/ReadImage/544.
10:00:08 site1.1     | convert-im6.q16: no images defined `/tmp/image_processing20211007-8992-1lsau5b.png' @ error/convert.c/ConvertImageCommand/3258.
10:00:08 site1.1     | ):
10:00:08 site1.1     |     1: ruby:
10:00:08 site1.1     |     2:   price = "#{item.price}元" if item.price.present?
10:00:08 site1.1     |     3:   image_url = (item.wrapper.attached? && item.wrapper.variable?) ? item.wrapper.variant(resize_to_fill: [250, 250]).processed.url : asset_path('no-image.png')
10:00:08 site1.1     |     4: 
10:00:08 site1.1     |     5: .col-xl-3.col-md-4.col-sm-6.col-6.p-1
10:00:08 site1.1     |     6:   .card

ImageMagick doesn't seem to support webp

$ sudo apt-get install webp

阅读量: 633
发布于:
修改于: