Skip to content

Instantly share code, notes, and snippets.

@MohitDabas
Created June 30, 2020 06:36
Show Gist options
  • Save MohitDabas/eec5fa39a0d7fc43cf28aa926d5654b1 to your computer and use it in GitHub Desktop.
Save MohitDabas/eec5fa39a0d7fc43cf28aa926d5654b1 to your computer and use it in GitHub Desktop.
The following gist contain information regarding setting up environment for remote code debugging on docker.
#mvn run on a particular port
mvn jetty:run -D jetty.port=9229
#mvn debug
export MAVEN_OPTS="-Xdebug -Xnoagent -Xrunjdwp:transport=dt_socket,address=0.0.0.0:9090,server=y,suspend=n"
#visual studio debug config
{
"version": "0.2.0",
"configurations": [
{
"type": "java",
"name": "Debug (Launch)",
"request": "launch",
"mainClass": "",
"args": ""
},
{
"type": "java",
"name": "Debug (Attach)",
"request": "attach",
"hostName": "localhost",
"port": 9090
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment