所需软件
1、JDK:8+
安装包:https://www.oracle.com/java/technologies/javase/javase8-archive-downloads.htmlopen in new window
安装文档:https://cloud.tencent.com/developer/article/1698454open in new window
2、Redis 3.0+
安装包:https://github.com/MicrosoftArchive/redis/releasesopen in new window
安装文档:https://www.redis.com.cn/redis-installation.htmlopen in new window
3、Maven 3.0+
安装文档:https://www.cnblogs.com/liuhongfeng/p/5057827.htmlopen in new window
安装包:https://archive.apache.org/dist/maven/maven-3/3.9.1/binaries/open in new window
4、MYSQL 5.7+
安装文档:https://www.jb51.net/article/256014.htmopen in new window
安装包:https://downloads.mysql.com/archives/community/open in new window
5、Nginx
安装包:http://nginx.org/en/download.htmlopen in new window
安装文档:https://developer.aliyun.com/article/1045494open in new window
6、Node
不需要安装到服务器,运维本地安装就行,主要是用来编译前端代码的
安装包:https://nodejs.org/zh-cn/downloadopen in new window
安装文档:https://www.liaoxuefeng.com/wiki/1022910821149312/1023025597810528open in new window
#后端部署
#导入SQL
导入SQL
#mysql/redis配置
#在父级pom.xml输入命令 mvn clean install 或者用idea工具操作
maven命令
#配置默认日志文件地址
/data/logs/kucun
#运行项目
nohup java -jar -Xmx512m jar包地址 --spring.profiles.active=prod>/dev/null 2>&1 &
#前端部署
#修改.env.production文件的访问路径
前端配置
#安装依赖
npm install --registry=https://registry.npmmirror.comopen in new window
#构建生产环境
npm run build:prod
构建完成后将dist文件夹复制到服务器内