Tomcat 04_部署Jpress

环境:jpress + mariadb ==> 192.168.189.60 Centos 7.4

准备软件:
启动tomcat
/opt/tomcat/bin/startup.sh
http://www.xchinagroup.top/softdown/centos7/30_tomcat/jpress.war

将jpress-web-newest.war 上传到 tomcat 主目录 /opt/tomcat/webapps



安装mariadb

yum install mariadb-server -y
systemctl start mariadb
systemctl enable mariadb
mysqladmin password Dfsc123321

创建数据库,并添加一个账户
create database jpress default character set utf8;
grant all on jpress.* to jpress@'192.168.%' identified by 'dfsc123';
flush privileges;

+++++++++
测试用户登录:你会发现,新建的这个用户,是不能在这台服务器上登录的,但是远程可以登录。





这是因为,mariadb 在这里,将你的IP做了反向的DNS解析,多此一举。

修改my.cnf 将其他关掉
vim /etc/my.cnf

在[[mysqld] 这个模块下面添加:
skip-name-resolve

保存退出,重启mariadb 。


++++++++
浏览器中打开 http://192.168.189.60:8080/jpress








+++++++++++++++++
重启tomcat






后台管理页面: