tinker-热更新私有化,补丁静态文件存放阿里云oss

tinker

参考地址:https://github.com/typ0520/tinker-manager/tree/master/patchserver

网盘下载patch-server-1.2.0-ALL,地址:

https://pan.baidu.com/s/1minrdgO?_at_=1695434151520#list/path=%2Ftinker-manager

解压patch-server-1.2.0-ALL.zip

#配置jdk和tomcat环境略。上传2个war包到webapps目录
hotfix-apis.war
hotfix-console.war

修改2个配置文件hotfix-apis.properties、hotfix-console.properties,linux就放到/opt/config/目录,没有就创建,修改数据库,端口和静态文件存放和访问地址(ossfs方式挂载oss到file_storage_path目录)。
#hotfix-apis.properties数据库配置和数据导入略,端口使用8099

修改hotfix-console.properties
#补丁文件存储路径 如果做测试可以直接使用tomcat作为静态服务器只需要把下面${你的tomcat路径}改成对应的就行了;**如果是用于生产环境可以使用nginx(修改为你的静态服务对应的根目录)
file_storage_path=/usr/local/apache-tomcat-8.5.69/webapps/patch-manager-static #将此目录挂载oss,通过ossfs方式。
在这里插入图片描述

#补丁文件存储路径 如果做测试可以直接使用tomcat作为静态服务器只需要把下面${你的tomcat路径}改成对应的就行了;**如果是用于生产环境可以使用nginx(修改为你的静态服务对应的根目录)
file_storage_path=/usr/local/apache-tomcat-8.5.69/webapps/patch-manager-static
#下载补丁文件静态服务器地址 **这个服务的根目录需要设置为上面配置的(${file_storage_path})的路径
patch-static-url=http://app.xxx.cn #oss访问域名
#控制台服务地址
tm-manager-url=http://localhost:8099/hotfix-console
#facade服务的地址
tm-facade-url=http://localhost:8099/hotfix-apis

访问地址

http://xxx.xxx.xxx.xxx:8099/hotfix-console/regist?redirect=/app/list

静态文件存入阿里云的oss,通过ossfs挂载,参考:https://help.aliyun.com/zh/oss/developer-reference/ossfs-installation

my-bucket
#挂载
ossfs my-bucket /usr/local/apache-tomcat-8.5.69/webapps/patch-manager-static -o url=http://oss-cn-qingdao-internal.aliyuncs.com

在这里插入图片描述

#卸载

fusermount -u /usr/local/apache-tomcat-8.5.69/webapps/patch-manager-static
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值