Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
jinli gu
Litemall
Commits
6ba6d107
Commit
6ba6d107
authored
Mar 31, 2018
by
Junling Bu
Browse files
fix[deploy]:upload.sh脚本设置了错误的litemall-db路径。
parent
22ff0f92
Changes
3
Hide whitespace changes
Inline
Side-by-side
deploy/util/upload.sh
View file @
6ba6d107
...
@@ -20,8 +20,8 @@ cp -f ./litemall-admin-api/target/litemall-admin-api-*.jar ./deploy/litemall-ad
...
@@ -20,8 +20,8 @@ cp -f ./litemall-admin-api/target/litemall-admin-api-*.jar ./deploy/litemall-ad
tar
-zcvf
./deploy/litemall-admin/dist.tar
-C
./litemall-admin/dist
.
tar
-zcvf
./deploy/litemall-admin/dist.tar
-C
./litemall-admin/dist
.
# 复制数据库
# 复制数据库
cp
-f
./litemall-db/sql/litemall_schema.sql ./deploy/litemall
_
db/litemall_schema.sql
cp
-f
./litemall-db/sql/litemall_schema.sql ./deploy/litemall
-
db/litemall_schema.sql
cp
-f
./litemall-db/sql/litemall.sql ./deploy/litemall
_
db/litemall.sql
cp
-f
./litemall-db/sql/litemall.sql ./deploy/litemall
-
db/litemall.sql
# 上传云主机
# 上传云主机
scp
-i
$ID_RSA
-r
./deploy ubuntu@
$CVM
:/home/ubuntu/
scp
-i
$ID_RSA
-r
./deploy ubuntu@
$CVM
:/home/ubuntu/
doc/1.md
View file @
6ba6d107
...
@@ -501,9 +501,15 @@ https://docs.spring.io/spring-boot/docs/1.5.10.RELEASE/reference/htmlsingle/#dep
...
@@ -501,9 +501,15 @@ https://docs.spring.io/spring-boot/docs/1.5.10.RELEASE/reference/htmlsingle/#dep
7.
自动上传脚本
7.
自动上传脚本
为了简化步骤1和步骤2,完成了util/upload.sh脚本,用户需要设置相应的云主机IP和密钥文件路径。
为了简化步骤1和步骤2,完成了
deploy/
util/upload.sh脚本,用户需要设置相应的云主机IP和密钥文件路径。
该脚本会自动把当前项目不同模块下的最终部署文件复制到deploy文件夹中,然后上传到云主机。
该脚本会自动把当前项目不同模块下的最终部署文件复制到deploy文件夹中,然后上传到云主机。
注意:
注意:
> 上传脚本没有自动做Spring Boot项目打包和Vue项目打包工作
> 上传脚本没有自动做Spring Boot项目打包和Vue项目打包工作
> 因此运行该脚本前请确认最终部署文件已经生成。
> 因此运行该脚本前请确认最终部署文件已经生成。
> 如果用户觉得需要,可以自行在upload.sh脚本中添加相应的编译打包命令。
> 如果用户觉得需要,可以自行在upload.sh脚本中添加相应的编译打包命令。
\ No newline at end of file
如下图所示,上传脚本自动上传deploy文件夹到云主机:

需要指出的是,这里的upload.sh脚本是private文件夹中的文件,因为private文件夹是
在.gitignore中设置忽略,因此upload.sh脚本里面可以包含一些隐私信息,
如云主机IP和当前系统私钥文件地址,而其他内容则和deploy/util/upload.sh完全一致。
\ No newline at end of file
doc/pic1/1-7.png
0 → 100644
View file @
6ba6d107
129 KB
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment