参考文章 https://blog.csdn.net/qq_28139021/article/details/72763878
docker环境中缺少基础库:
1. apt update
2. apt install vim openssh-server inetutils-ping net-tools
3. apt install software-properties-common
4. 从其他机器拷贝 'locale-gen'
5. locale-gen en_US.UTF-8
6. LC_ALL=en_US.UTF-8 add-apt-repository -y ppa:ondrej/php
如果上面报错:
W: GPG error: http://ppa.launchpad.net/ondrej/php/ubuntu xenial InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 4F4EA0AAE5267A6C
W: The repository 'http://ppa.launchpad.net/ondrej/php/ubuntu xenial InRelease' is not signed.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
则运行 apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 4F4EA0AAE5267A6C
7. apt update
8. apt-get -y install php5.6 php5.6-mcrypt php5.6-mbstring php5.6-curl php5.6-cli php5.6-mysql php5.6-gd php5.6-intl php5.6-xsl php5.6-zip