Такая проблема. Есть продукт сервер, где код представленный ниже работает нормально. Сейчас пытаюсь все это развернуть через докер и тот же самый самый код выдает ошибку
Error
must specify image size `/tmp/magick-pvKVqqZOgZLEImdlmik0Tl8aUFPkNFlM' @ error/mvg.c/ReadMVGImage/186
Code
$imagick = new Imagick();
$imagick->readImageBlob($svg);
Dockerfile
FROM composer:2.1 AS composer
FROM php:7.3-fpm as base
RUN apt update && apt install -y --no-install-recommends \
git \
openssh-client \
libzip-dev \
libpq-dev \
unzip \
libpng-dev \
libjpeg-dev \
libwebp-dev \
libmagickwand-dev \
ffmpeg && \
rm -r /var/lib/apt/lists/*
# PHP extensions
RUN pecl install pcov
COPY php.ini /usr/local/etc/php/conf.d/40-custom.ini
RUN docker-php-ext-configure pdo_mysql --with-pdo-mysql=mysqlnd && \
docker-php-ext-configure opcache --enable-opcache && \
docker-php-ext-install zip pdo_pgsql pdo_mysql mysqli bcmath opcache gd exif && \
docker-php-ext-enable zip pdo_mysql mysqli opcache gd pdo_pgsql pcov
WORKDIR /var/www/laravel9
ENV PATH="$PATH:/src/vendor/bin"
COPY --from=composer /usr/bin/composer /usr/bin/composer
COPY composer.* ./
RUN pecl install imagick && docker-php-ext-enable imagick
FROM base as prod
COPY . ./
RUN chgrp -R www-data storage bootstrap/cache && chmod -R ug+rwx storage bootstrap/cache \
&& composer dump-autoload --optimize
FROM base as dev
RUN composer install --no-scripts --no-autoloader --no-interaction --dev
COPY . ./
RUN chgrp -R www-data storage bootstrap/cache && chmod -R ug+rwx storage bootstrap/cache \
&& composer dump-autoload --optimize
svg
<svg xmlns="http://www.w3.org/2000/svg" border="0" data-ac-wrapper-id="1" width="100%" height="100%" class="anychart-ui-support" ac-id="ac_stage_0" style="display: block;"><defs></defs><g data-ac-wrapper-id="2" id="ac_layer_1"><g data-ac-wrapper-id="39" id="ac_layer_12"><path data-ac-wrapper-id="42" id="ac_path_15" fill="none" stroke="black" d="M 45.844 20 L 100.578 20 A 3 3 0 0 1 103.578 23 L 103.578 65 A 5 5 0 0 1 98.578 70 L 47.844 70 A 5 5 0 0 1 42.844 65 L 42.844 23 A 3 3 0 0 1 45.844 20 Z"></path><text data-ac-wrapper-id="43" font-family="Arial, Helvetica, sans-serif" font-size="14px" fill="#000" direction="ltr" text-anchor="start" x="52.58990625" y="50.75" id="ac_text_16" style="opacity: 1;"><tspan x="52.58990625" dy="0">П20лв</tspan></text><path data-ac-wrapper-id="44" id="ac_path_17" fill="none" stroke="black" d="M 42.844 56 L 103.578 56"></path><text data-ac-wrapper-id="45" font-family="Arial, Helvetica, sans-serif" font-size="11px" font-weight="bold" fill="#000" direction="ltr" text-anchor="start" x="69.539625" y="66.75" id="ac_text_18" style="opacity: 1; cursor: pointer;"><tspan x="69.539625" dy="0">X</tspan></text><text data-ac-wrapper-id="46" font-family="Arial, Helvetica, sans-serif" font-size="11px" font-weight="bold" fill="#000" direction="ltr" text-anchor="start" x="90.24165625" y="66.75" id="ac_text_19" style="opacity: 1; cursor: pointer;"><tspan x="90.24165625" dy="0">></tspan></text><path data-ac-wrapper-id="47" id="ac_path_1a" fill="none" stroke="black" d="M 52.514 90 L 73.211 70"></path><path data-ac-wrapper-id="50" id="ac_path_1d" fill="none" stroke="black" d="M 149.422 20 L 204.156 20 A 3 3 0 0 1 207.156 23 L 207.156 65 A 5 5 0 0 1 202.156 70 L 151.422 70 A 5 5 0 0 1 146.422 65 L 146.422 23 A 3 3 0 0 1 149.422 20 Z"></path><text data-ac-wrapper-id="51" font-family="Arial, Helvetica, sans-serif" font-size="14px" fill="#000" direction="ltr" text-anchor="start" x="151.62103125" y="50.75" id="ac_text_1e" style="opacity: 1;"><tspan x="151.62103125" dy="0">ДКР160</tspan></text><path data-ac-wrapper-id="52" id="ac_path_1f" fill="none" stroke="black" d="M 146.422 56 L 207.156 56"></path><text data-ac-wrapper-id="53" font-family="Arial, Helvetica, sans-serif" font-size="11px" font-weight="bold" fill="#000" direction="ltr" text-anchor="start" x="153.32965625" y="66.75" id="ac_text_1g" style="opacity: 1; cursor: pointer;"><tspan x="153.32965625" dy="0"><</tspan></text><text data-ac-wrapper-id="54" font-family="Arial, Helvetica, sans-serif" font-size="11px" font-weight="bold" fill="#000" direction="ltr" text-anchor="start" x="173.117625" y="66.75" id="ac_text_1h" style="opacity: 1; cursor: pointer;"><tspan x="173.117625" dy="0">X</tspan></text><path data-ac-wrapper-id="55" id="ac_path_1i" fill="none" stroke="black" d="M 142.514 90 L 176.789 70"></path><text data-ac-wrapper-id="57" font-family="Arial, Helvetica, sans-serif" font-size="11px" font-weight="bold" fill="red" direction="ltr" text-anchor="start" x="56.38678125" y="31.75" id="ac_text_1k" style="opacity: 1;"><tspan x="56.38678125" dy="0">14 690</tspan></text><text data-ac-wrapper-id="58" font-family="Arial, Helvetica, sans-serif" font-size="11px" font-weight="bold" fill="red" direction="ltr" text-anchor="start" x="156.9061875" y="31.75" id="ac_text_1l" style="opacity: 1;"><tspan x="156.9061875" dy="0">139 610</tspan></text></g><g data-ac-wrapper-id="40" id="ac_layer_13" transform="matrix(1,0,0,1,42.514,90)"><path data-ac-wrapper-id="41" id="ac_path_14" fill="none" stroke="black" d="M 8 0 L 12 0 A 8 8 0 0 1 20 8 L 20 102 A 8 8 0 0 1 12 110 L 8 110 A 8 8 0 0 1 -8.881784197001252e-16 102 L 0 8 A 8 8 0 0 1 8 1.7763568394002505e-15 Z"></path><path data-ac-wrapper-id="48" id="ac_path_1b" fill="none" stroke="black" d="M 28 0 L 172 0 A 8 8 0 0 1 180 8 L 180 27 A 8 8 0 0 1 172 35 L 28 35 A 8 8 0 0 1 20 27 L 20 8 A 8 8 0 0 1 28 1.7763568394002505e-15 Z"></path><path data-ac-wrapper-id="49" id="ac_path_1c" fill="none" stroke="black" d="M 28 35 L 172 35 A 8 8 0 0 1 180 43 L 180 107 A 8 8 0 0 1 172 115 L 28 115 A 8 8 0 0 1 20 107 L 20 43 A 8 8 0 0 1 28 35 Z"></path></g><g data-ac-wrapper-id="56" id="ac_layer_1j"></g></g></svg>