[Alpine OS][Docker]PHP 8.1 GDのインストール

LINEで送る
Pocket

  • Dockerfile
RUN docker-php-ext-install intl pdo_mysql soap gd
RUN docker-php-ext-configure gd \
    --with-freetype=/usr/include/ \
    --with-jpeg=/usr/include/ \
    && docker-php-ext-install -j$(nproc) gd
  • 確認
bash-5.1# php -r 'print_r(gd_info());'
Array
(
    [GD Version] => bundled (2.1.0 compatible)
    [FreeType Support] => 1
    [FreeType Linkage] => with freetype
    [GIF Read Support] => 1
    [GIF Create Support] => 1
    [JPEG Support] => 1
    [PNG Support] => 1
    [WBMP Support] => 1
    [XPM Support] =>
    [XBM Support] => 1
    [WebP Support] =>
    [BMP Support] => 1
    [AVIF Support] =>
    [TGA Read Support] => 1
    [JIS-mapped Japanese Font Support] =>
)

インストール方法は7.4と変わらない

Was this helpful?

0 / 0

コメントを残す 0

Your email address will not be published. Required fields are marked *