dooman87 / imagemagick-docker Goto Github PK
View Code? Open in Web Editor NEWRunning the latest version of imagemagick inside container
Home Page: https://hub.docker.com/r/dpokidov/imagemagick
License: MIT License
Running the latest version of imagemagick inside container
Home Page: https://hub.docker.com/r/dpokidov/imagemagick
License: MIT License
Hi Team,
I'm trying to add text on an image. But I'm getting following error.
'convert: unable to read font `helvetica' @ error/annotate.c/RenderFreetype/1619.'
Command used:
docker run -v imagemagick:/imgs dpokidov/imagemagick $1 label:'Faerie Dragon' -font Z003-Medium-Italic -gravity Center -append $3
I've listed the font's supported and I see Z003-Medium-Italic. So, can some one please help me with correct command?
Thanks,
Deepak
I think set WORKDIR /imgs
to the dockerfile will be convenient.
This setup can make:
docker run --entrypoint=identify -v /your/images:/imgs dpokidov/imagemagick /imgs/sample.png
into
docker run --entrypoint=identify -v /your/images:/imgs dpokidov/imagemagick sample.png
debian use: debian:stretch-slim
which is debian 9 (latest version is 10) I recommend using sid-slim
(it's unstable, latest version)
fedora use: 27 (latest version is 32) I recommend using rawhide
(it's unstable/next-version-in-development) or latest
Hello,
When I was creating the Ubuntu image, I noted a strange BMP/ICO behavior, and one of my libraries that work with binaries created by the docker image was not working as expected.
In order to better understand what's happening, I tried to isolate the minimal piece of code to reproduce the error.
I created https://github.com/Kikobeats/ico-issue repo that makes the issue reproducible. Relevant files:
My guess is it's an issue related to something different at the CPU architecture level and how binaries are built, but there is too much thing in that space I'm skipping
Happy if you can take a look to check if something looks wrong to you. The Dockerfile there is a copy/paste of the ubuntu version (because entrypoint is not helping
We detected that set profile option is not working like is exposed in this post:
https://stackoverflow.com/questions/47414462/php-imagick-wont-add-icc-color-profile
It's possible to enable configure/make flag lcms in your image?
I had success converting files with just:
FROM alpine
RUN apk add --no-cache imagemagick
Installing this dependency during build takes ~10s. OK: 101 MiB in 70 packages
If you try and use this container on an M1 mac you get this error
Status: Downloaded newer image for dpokidov/imagemagick:latest
WARNING: The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested
Solutions
If using github actions, you can make the builds multiplatform by adding the platform
with stanza
When I try to convert an animated png file (like https://en.wikipedia.org/wiki/File:Animated_PNG_example_bouncing_beach_ball.png) to a gif I get an error saying ffmpeg isn't installed in the container
docker run -v /tmp/imgs:/imgs dpokidov/imagemagick apng:/imgs/testing_animated.png /imgs/test_apng.gif
sh: 1: ffmpeg: not found
convert: no images defined `/imgs/test_apng.gif' @ error/convert.c/ConvertImageCommand/3342.
Wondering if you can help me out. I have a folder of images, mostly jpg & jpeg's that i need to reduce the size to 1920x1080. Ive used the entrypoint command with resize however cant seem to figure out how to specify the 1920x1080.
Thank you for the help!
Hello Dmitry!
Don't work convert:
docker run --entrypoint=convert -v /images/:/imgs dpokidov/imagemagick /imgs/3.raf -resize 1920x -strip -interlace Plane -quality 80 jpg:/imgs/3.jpg
error:
/imgs/3.raf: Unexpected end of file
convert: Input/output error `/imgs/3.raf' @ error/dng.c/ReadDNGImage/429.
but:
docker run --entrypoint=identify -v images/:/imgs dpokidov/imagemagick /imgs/3.raf
is good:
/imgs/3.raf RAF 80x200 6016x4014+2968+1906 16-bit sRGB 41.0209MiB 0.000u 0:00.029
and raw delegate existed:
docker run --entrypoint=identify dpokidov/imagemagick -version
Features: Cipher DPC HDRI OpenMP
Delegates (built-in): jng jpeg lcms png raw tiff webp zlib
File in attachment.
Could you add supporting of it and add many others delegates to container?
Thanx in advance.
I pulled the latest image from the docker hub: https://hub.docker.com/r/dpokidov/imagemagick and trying to convert bunch of jpg files to pdf files
with magick mogrify
. https://imagemagick.org/script/mogrify.php
Executed command: docker run --entrypoint=identify -v $(pwd):/imgs dpokidov/imagemagick magick mogrify -format pdf *.jpg
I'm not sure whether this command is correct or not or what is the reason behind this error.
Good afternoon my friends
I have the following imagemagick command to overlay images
composite -gravity Center image_resize.png canvas.png image.png
When I try the following way using its container, it returns an empty image
docker run -v ~/Imagens:/imgs dpokidov/imagemagick \
-composite -gravity Center /imgs/image_resize.png /imgs/canvas.png /imgs/$(date +%Y-%m-%d_%H-%M-%S)_image.png
Thank you in advance if you can help
An issue has been fixed in the latest version.
ImageMagick/ImageMagick#5182
Please consider upgrading it.
I'd like to suggestion you put a DockerHub link here:
Hello, I'm working on ImageMagickPHP and I'd like to use your Docker image to simplify ImageMagick's installation for testing purposes.
So far, your image provides everything I need, however I can't really run it from my scripts.
I tested locally on a Ubuntu 20.04 WSL2 setup.
For the record, I also have a local installation of ImageMagick 7.0.11-6 Q16 x86_64.
Here is what I do to reproduce:
First, create a docker_entrypoint.sh
file containing only this:
#!/bin/sh
sh -c $@
Then run this:
docker run \
--rm \
--volume `pwd`:`pwd` \
--workdir=`pwd` \
--entrypoint="`pwd`/docker_entrypoint.sh" \
dpokidov/imagemagick:latest \
magick \
-version
What I'd like to see is this:
Version: ImageMagick 7.0.11-2 Q16 x86_64 2021-02-25 https://imagemagick.org
Copyright: (C) 1999-2021 ImageMagick Studio LLC
License: https://imagemagick.org/script/license.php
Features: Cipher DPC HDRI OpenMP(4.5)
Delegates (built-in): heic jng jpeg png webp xml zlib
But instead, I see this:
Error: Invalid argument or not enough arguments
Usage: magick tool [ {option} | {image} ... ] {output_image}
Usage: magick [ {option} | {image} ... ] {output_image}
magick [ {option} | {image} ... ] -script {filename} [ {script_args} ...]
magick -help | -version | -usage | -list {option}
However, this works when I execute a command from inside the container, like this:
$ docker run \
--rm \
-it \
--volume `pwd`:`pwd` \
--workdir=`pwd` \
--entrypoint="`pwd`/docker_entrypoint.sh" \
dpokidov/imagemagick:latest \
bash
root@8e1a1289fd8f:/var/www/ImageMagickPHP# magick -version
Version: ImageMagick 7.0.11-2 Q16 x86_64 2021-02-25 https://imagemagick.org
Copyright: (C) 1999-2021 ImageMagick Studio LLC
License: https://imagemagick.org/script/license.php
Features: Cipher DPC HDRI OpenMP(4.5)
Delegates (built-in): heic jng jpeg png webp xml zlib
Any idea on what I'm missing? ๐ค
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.