-
Notifications
You must be signed in to change notification settings - Fork 114
Description
Hi,
I have got a non-standard way of Node remote debugging worked. I'd like to ask advice on getting to work the standard way if possible.
Current approach
I am running App Service with a non-standard JS file location booted from an NPM script. E.g.
{
"scripts": {
"dev": "node src/main/main.js"
}
}
I have currently got remote debugging working like this:
{
"scripts": {
"dev": "node src/main/main.js",
"dev_debug": "node --inspect=0.0.0.0:11111 src/main/main.js"
}
}
Then use AZ CLI SSH + port forwarding to get the port to my local machine. This work ok.
Other attempts
I initially had the following:
{
"scripts": {
"dev": "node src/main/main.js",
"dev_debug": "node --inspect=0.0.0.0:$APPSVC_TUNNEL_PORT src/main/main.js"
}
}
But I found that $APPSVC_TUNNEL_PORT did not have a value on the App Service machine. Do I need to enable some other setting to make sure this env var is populated correctly?
Or is there some better way entirely to get remote debugging working with Node and a custom file/script?
Any advice would be much appreciated!
Thanks