在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
1,配置CentOs8的yum源vim /etc/yum.repos.d/CentOS-AppStream.repo [AppStream] name=CentOS-$releasever - AppStream baseurl=http://mirrors.aliyun.com/centos/$releasever/AppStream/$basearch/os/ gpgcheck=1 enabled=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial
vim /etc/yum.repos.d/CentOS-Base.repo [BaseOS] name=CentOS-$releasever - Base baseurl=http://mirrors.aliyun.com/centos/$releasever/BaseOS/$basearch/os/ gpgcheck=1 enabled=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial
vim /etc/yum.repos.d/CentOS-Epel.repo [epel] name=CentOS-$releasever - Epel baseurl=http://mirrors.aliyun.com/epel/8/Everything/$basearch enabled=1 gpgcheck=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-8 2,yum源配置成功后yum clean all #命令清除yum缓存元数据3,yum makecache #重新建立yum缓存4,安装epel存储库sudo dnf -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm 5,确认epel库是否安装成功rpm -qa | grep epel 6,安装remi存储库dnf install https://rpms.remirepo.net/enterprise/remi-release-8.rpm 7,确认remi存储库是否安装成功8,成功添加EPEL和Remi存储库后,执行以下命令以获取可用PHP模块流的列表dnf module list php 9,dnf module reset php #重置php模块10,根据第八步中的php流模块,启用对应php版本的流模块,这里我们安装的是php7.4的版本,所以启用remi-7.4版本的流dnf module enable php:remi-7.4 11,安装PHP,此命令还安装许多其他软件包dnf install php php-cli php-common 12,查看php是否安装成功 |
2022-07-29
2022-08-30
2022-08-17
2022-11-06
2022-08-18
请发表评论