CentOS 7基于LAMP架构部署论坛系统discuz

操作系统:CentOS 7

[root@localhost ~]# cat /etc/redhat-release 
CentOS Linux release 7.7.1908 (Core)

一、基础环境
系统初始化
二、安装LAMP

# yum -y install httpd mariadb-server mariadb php php-mysql gd php-gd
# systemctl start httpd mariadb
# systemctl enable httpd mariadb

三、安装Discuz
1.导入discuz网站源代码

#wget http://download.comsenz.com/DiscuzX/2.5/Discuz_X2.5_SC_UTF8.zip
#mkdir /webdata/discuz
#unzip Discuz_X2.5_SC_UTF8.zip
#cp -rf upload/* /webdata/discuz/
#chown -R apache.apache /webdata/discuz/

2.Apache配置虚拟主机

#vim /etc/httpd/conf.d/discuz.conf

ServerName www.discuz.com
DocumentRoot /webroot/discuz


Require all granted

#systemctl restart httpd

3.准备数据库

#mysql
MariaDB [(none)]> create database discuz ;
MariaDB [(none)]> show databases;
| discuz             |

4.安装discuz[客户端]

#vim /etc/hosts
x.x.x.x    www.discuz.com    //x.x.x.x是LANP服务器IP地址

浏览器访问
按照要求安装discuz。

你可能感兴趣的:(CentOS,linux,centos,apache)