arthas配置方法:
1.增加pom,增加配置文件application.yml里面内容:
pom.xml:
<dependency>
<groupId>com.taobao.arthas</groupId>
<artifactId>arthas-spring-boot-starter</artifactId>
<version>3.6.7</version>
</dependency>
application.yml:
arthas:
#arthas服务端域名
tunnel-server: ws://xx.xx.xx.xx:8777/ws
#客户端id,应用名_随机值,js会截取前面的应用名
agent-id: MyTest_${random.value}
2.下载arthas tunnel server fat jar包
github:https://github.com/alibaba/arthas/releases
文档:https://arthas.aliyun.com/doc/tunnel.html
1.修改配置文件
使用winrar打开,修改内部的arthas-tunnel-server-3.6.7-fatjar.jar\BOOT-INF\classes\application.properties:
# arthas tunnel server host
arthas.server.host=0.0.0.0
# arthas tunnel server port
arthas.server.port=8777
server.port=8081
# for all endpoints
management.endpoints.web.exposure.include=*
# default user name
spring.security.user.name=arthas
# If set to true, be sure to do security protection to ensure that the server will not be illegally accessed
arthas.enable-detail-pages=true
spring.cache.type=caffeine
spring.cache.cache-names=inMemoryClusterCache
spring.cache.caffeine.spec=maximumSize=3000,expireAfterAccess=3600s
#arthas.embedded-redis.enabled=true
#arthas.embedded-redis.settings=maxmemory 128M
#spring.redis.host=127.0.0.1
---------------以上为修改好的配置文件所有内容,主要修改以下三行
arthas.enable-detail-pages=true
arthas.server.port=8777
server.port=8081
2.修改前台文件:
arthas-tunnel-server-3.6.7-fatjar.jar\BOOT-INF\classes\static\static\js\tunnel-0391fa5f.js
将里面的7777修改为8777
3.启动两个项目即可
http://xxx.xx.xx.x:8081/apps.html
执行命令相关文档和资料:
https://arthas.aliyun.com/doc/quick-start.html#_6-watch
https://developer.aliyun.com/article/1009026