Udpate remote examples for docker/cpptools
This commit is contained in:
parent
e7fb49f03d
commit
d12c0897f2
1 changed files with 25 additions and 12 deletions
|
|
@ -765,6 +765,8 @@ and have to tell cpptools a few more options.
|
||||||
"remote": {
|
"remote": {
|
||||||
"host": "${host}",
|
"host": "${host}",
|
||||||
"account": "${account}",
|
"account": "${account}",
|
||||||
|
// or, alternatively "container": "${ContainerID}"
|
||||||
|
|
||||||
"runCommand": [
|
"runCommand": [
|
||||||
"gdbserver",
|
"gdbserver",
|
||||||
"--once",
|
"--once",
|
||||||
|
|
@ -772,14 +774,19 @@ and have to tell cpptools a few more options.
|
||||||
"--disable-randomisation",
|
"--disable-randomisation",
|
||||||
"0.0.0.0:${port}",
|
"0.0.0.0:${port}",
|
||||||
"%CMD%"
|
"%CMD%"
|
||||||
}
|
},
|
||||||
|
"delay": "1000m" // optional
|
||||||
},
|
},
|
||||||
"attach": {
|
"attach": {
|
||||||
"remote": {
|
"remote": {
|
||||||
"host": "${host}",
|
"host": "${host}",
|
||||||
"account": "${account}",
|
"account": "${account}",
|
||||||
|
// or, alternatively "container": "${ContainerID}"
|
||||||
|
|
||||||
"pidCommand": [
|
"pidCommand": [
|
||||||
"/path/to/secret/script/GetPIDForService", "${ServiceName}"
|
// e.g. "/path/to/secret/script/GetPIDForService", "${ServiceName}"
|
||||||
|
// or...
|
||||||
|
"pgrep", "executable"
|
||||||
],
|
],
|
||||||
"attachCommand": [
|
"attachCommand": [
|
||||||
"gdbserver",
|
"gdbserver",
|
||||||
|
|
@ -796,12 +803,13 @@ and have to tell cpptools a few more options.
|
||||||
// application never attaches, try using the following to manually
|
// application never attaches, try using the following to manually
|
||||||
// force the trap signal.
|
// force the trap signal.
|
||||||
//
|
//
|
||||||
"initCompleteCommand": [
|
// "initCompleteCommand": [
|
||||||
"kill",
|
// "kill",
|
||||||
"-TRAP",
|
// "-TRAP",
|
||||||
"%PID%"
|
// "%PID%"
|
||||||
]
|
// ]
|
||||||
}
|
},
|
||||||
|
"delay": "1000m" // optional
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
@ -811,22 +819,27 @@ and have to tell cpptools a few more options.
|
||||||
"remote-cmdLine": [ "/path/to/the/remote/executable", "args..." ],
|
"remote-cmdLine": [ "/path/to/the/remote/executable", "args..." ],
|
||||||
"remote-request": "launch",
|
"remote-request": "launch",
|
||||||
"configuration": {
|
"configuration": {
|
||||||
"request": "attach", // yes, attach!
|
"request": "launch",
|
||||||
|
|
||||||
"program": "/path/to/the/local/executable",
|
"program": "/path/to/the/local/executable",
|
||||||
|
"cwd": "${workspaceRoot},
|
||||||
"MIMode": "gdb",
|
"MIMode": "gdb",
|
||||||
"miDebuggerAddress": "${host}:${port}"
|
"miDebuggerServerAddress": "${host}:${port}",
|
||||||
|
"sourceFileMap#json": "{\"${RemoteRoot}\": \"${workspaceRoot}\"}"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"remote attach": {
|
"remote attach": {
|
||||||
"adapter": "cpptools-remote",
|
"adapter": "cpptools-remote",
|
||||||
"remote-request": "attach",
|
"remote-request": "attach",
|
||||||
"configuration": {
|
"configuration": {
|
||||||
"request": "attach",
|
"request": "launch",
|
||||||
|
|
||||||
"program": "/path/to/the/local/executable",
|
"program": "/path/to/the/local/executable",
|
||||||
|
"cwd": "${workspaceRoot},
|
||||||
"MIMode": "gdb",
|
"MIMode": "gdb",
|
||||||
"miDebuggerAddress": "${host}:${port}"
|
"miDebuggerServerAddress": "${host}:${port}",
|
||||||
|
"sourceFileMap#json": "{\"${RemoteRoot}\": \"${workspaceRoot}\"}"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue