【问题标题】:How to install bcmath on a debian:jessie php5.6?如何在 debian:jessie php5.6 上安装 bcmath?
【发布时间】:2018-04-26 13:37:08
【问题描述】:

我正在docker container 上运行一个 linux 实例。这是一个 php 5.6 的 debian:jessie。

我想安装 bcmath 模块,但没有成功。

有人知道怎么做吗?

root@1419c032c35f:/etc/php5/fpm# apt install php5.6-bcmath
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package php5.6-bcmath
E: Couldn't find any package by regex 'php5.6-bcmath'

【问题讨论】:

    标签: docker php-5.6 debian-jessie bcmath


    【解决方案1】:

    只需创建一个 Dockerfile,它将从您想要的镜像(上面链接的那个)构建并添加行

    RUN docker-php-ext-install bcmath
    

    【讨论】:

    • 完美,bcmath 现已启用。
    • 此解决方案也适用于使用 Alpine Linux 的 php:7.2-apache-stretch 图像。
    猜你喜欢
    • 2018-06-26
    • 2023-04-06
    • 2011-03-24
    • 2015-05-26
    • 1970-01-01
    • 2021-08-25
    • 1970-01-01
    • 2018-02-07
    相关资源
    最近更新 更多