Jetbrains 远程调试
#
支持的 IDELanguage | IDE | 版本 | 依赖插件 |
---|---|---|---|
Java | IntelliJ IDEA | Ultimate | N/A |
Go | IntelliJ IDEA | Ultimate | Go plugin |
GoLand | Professional | N/A | |
Python | IntelliJ IDEA | Ultimate | Python plugin |
PyCharm | Professional | N/A | |
PHP | IntelliJ IDEA | Ultimate | PHP plugin |
PHPStorm | Professional | N/A | |
Node.js | IntelliJ IDEA | Ultimate | Node.js plugin |
WebStrom | Professional | N/A |
#
调试流程- 选择您想要调试的工作负载
- 右键点击工作负载并选择
Dev Config
,编辑您的调试配置 - 然后右键再次点击此工作负载并选择 Remote Debug
- Nocalhost 将自动进入
DevMode
并开始远程调试
#
IDE 中的调试配置在进入调试模式前,如果您在现有的工作负载下还没有一个 Nocalhost 的调试配置,Nocalhost 将根据您的 Nocalhost 配置 创建一个新的 IDE 调试配置。 不同的 IDE 有不同的配置名称和模板。
Multi Configs
如果您已经在现有工作负载下有多个 Nocalhost 调试配置,Nocalhost 将使用第一个配置执行调试。 您可以在 IDE 的 Run/Debug Configurations
窗口中调整配置执行的顺序。

#
配置内容不同的开发人员的开发环境是不同的。 你应该根据实际情况来配置远程调试的配置。
#
配置示例- Java
- Python
- Go
- PHP
- Node.js
- Ruby
Nocalhost Configs
#
Maven ExampleThe shell command for Maven example:
jdk >= 1.8 and springBoot >=2.2.1.RELEASE
For jdk <=1.7 you should replace -agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:5005
with -Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=5005
For lower version of the springBoot you should replace -Drun.jvmArguments
with -Dspring-boot.run.jvmArguments
#
Gradle ExampleThe startup command for Gradle example:
Gradle's debug.sh
Nocalhost Configs
- VSCode
- Jetbrains
debug.sh
debug.sh
How does it Works?
Nocalhost using pydevd to debug Python application.

Nocalhost Configs
debug.sh
Nocalhost Configs
debug.sh
How does it works?
Nocalhost using Xdebug to debug PHP applications.

Nocalhost Configs
debug.sh
Nocalhost Configs
debug.sh