CentOS 7 部署 Jspgou 商城应用 [ TomCat ]

CentOS 7 部署 Jspgou 商城应用 [ TomCat ]_第1张图片

 

软件包

cd /root

tar -xzvf jdk-8u212-linux-x64.tar.gz -C /usr/local/
tar -xvzf apache-tomcat-8.5.69.tar.gz -C /usr/local/

cd /usr/local
mv jdk1.8.0_212/ java
mv apache-tomcat-8.5.69/ tomcat

1)Tomcat

vim /etc/profile

JAVA_HOME=/usr/local/java
PATH=$JAVA_HOME/bin:$PATH 
export JAVA_HOME PATH
CATALINA_HOME=/usr/local/tomcat 
export CATALINA_HOME

source /etc/profile

# 启动 Tomcat
/usr/local/tomcat/bin/startup.sh

# 关闭 Tomcat
/usr/local/tomcat/bin/shutdown.sh
# 测试
systemctl stop firewalld
systemctl disable firewalld

CentOS 7 部署 Jspgou 商城应用 [ TomCat ]_第2张图片

2)数据库

yum -y install mariadb mariadb-server

systemctl start mariadb
systemctl enable mariadb

# 创建数据库
mysql
create database jspgou default charset=utf8;
flush privileges;
quit;

# 更新密码
mysql
SET password=PASSWORD('P@ssw0rd123456');
flush privileges;
quit;

CentOS 7 部署 Jspgou 商城应用 [ TomCat ]_第3张图片

3)Jspgou

# 链接:https://pan.baidu.com/s/1oRgurQr80vfTe-89XgSd1g 
# 提取码:qok6 

ls /usr/local/tomcat/webapps/    # 默认网站的主目录

rm -rf /usr/local/tomcat/webapps/ROOT

cd ~;unzip jspgouV6-ROOT.zip

cp -r ROOT/ /usr/local/tomcat/webapps/

vim /usr/local/tomcat/webapps/ROOT/WEB-INF/config/jdbc.properties
jdbc.url=jdbc:mysql://127.0.0.1:3306/jspgou?characterEncoding=UTF-8
jdbc.username=root
jdbc.password=P@ssw0rd123456

4)导入数据

cd DB
mysql -u root -p -D jspgou < jspgou.sql
 
# 重启 Tomcat
/usr/local/tomcat/bin/shutdown.sh 
/usr/local/tomcat/bin/startup.sh

5)访问验证:

192.168.80.222:8080

CentOS 7 部署 Jspgou 商城应用 [ TomCat ]_第4张图片

6)管理后台

http://192.168.80.222:8080/jeeadmin/jspgou/index.do

CentOS 7 部署 Jspgou 商城应用 [ TomCat ]_第5张图片

CentOS 7 部署 Jspgou 商城应用 [ TomCat ]_第6张图片

你可能感兴趣的:(开源项目,centos)