其他分享
首页 > 其他分享> > 单机版Discuz网站LAMP架构部署

单机版Discuz网站LAMP架构部署

作者:互联网

查看LAMP环境,需要的软件包
# rpm -qa |grep mysql
# rpm -qa |grep php
# rpm -qa |grep httpd

1、安装apache:
# yum install -y httpd
# vim /etc/httpd/conf/httpd.conf

96 #下面这行的意思是允许所有计算机通过ip地址访问本地80端
97 ServerName localhost:80
98 ServerName www.lamp.com:80
165 <IfModule dir_module>
166 DirectoryIndex index.html index.php
167 </IfModule>

重启apache

# systemctl start httpd
# systemctl enable httpd

查看apache端口
# netstat -antp |grep httpd

查看apache版本
# httpd -v

2、安装mysql
# wget https://repo.mysql.com/mysql80-community-release-el7-5.noarch.rpm
# rpm -ivh mysql-community-release-el7-5.noarch.rpm
# yum install -y mysql-community-server

启动mysql
# systemctl restart mysqld
# systemctl enable mysqld

设置mysql的root密码
# mysql_secure_installation
# mysql -uroot -pcentos

3、安装php
# yum install -y php
# systemctl restart httpd
# ll /var/www/html/

4、安装discuz项目

下载discuz网站:https://gitee.com/ComsenzDiscuz/DiscuzX
# unzip discuz.zip
# cd discuz/
# mv * /var/www/html/
# chmod -R a+w /var/www/html/
# yum -y install php-mysqli
# systemctl restart httpd

标签:httpd,www,单机版,Discuz,LAMP,systemctl,mysql,php,rpm
来源: https://www.cnblogs.com/jdbinfo/p/15421271.html