1. 安装 epel 源
- yum -y install epel-release
- yum -y install http://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
2. 安装 Remi 仓库
yum -y install http://rpms.remirepo.net/enterprise/remi-release-7.rpm
3. 安装 yum 管理工具
yum -y install yum-utils
4.yum 安装 php
- yum-config-manager --enable remi-php70 #制定 php 包版本
- yum install php-fpm php-mysql php-curl php-gd php-mbstring php-mcrypt php-xml php-xmlrpc php-zip #安装 php 及相关组件
来源: http://www.bubuko.com/infodetail-2537323.html