type
status
date
slug
summary
tags
category
icon
password
😀
当我们在开发过程中遇到一些复杂的问题或需要对代码进行调试时,远程调试是一种非常有用的工具。使用 IntelliJ IDEA 进行远程调试可以让你在远程服务器上的应用程序中设置断点、查看变量和执行调试操作。

一、准备好springboot项目jar包

pom.xml
application.yml
controller
将项目打成jar包,上传到虚拟机的/tmp目录
将项目打成jar包,上传到虚拟机的/tmp目录

二、部署到虚拟机

切到/tmp目录,执行如下命令启动程序:
notion image
notion image

三、在IDEA中创建远程调试启动项

3.1 添加远程调试启动项

notion image
notion image

3.2 配置远程调试参数

notion image

四、测试

4.1 在指定代码处打断点

notion image

4.2 Debug启动远程调试

notion image

4.3 访问项目接口

接口url:http://192.168.150.123:6633/api/user/info
notion image
 
Docker搭建小雅影音库WebSocket如何保持长连接
Loading...