Remote Node debugging — specify remote JS file

Why is it not possible to specify remote JS file instead of local one?
I work on Windows but my code is Linux-specific so I use Linux VM and autodeploy code changes into VM.
Build configuration requires using of Webpack so I build my code in VM.
Now when I want to debug my app I can create remote Node.JS interpreter to use in Run configuration but I also have to specify a JavaScript file to run.
The thing is that I need to run bundled JS file (i.e. remote_path/dist/main.js) and I only build this code on remote server (VM) so I don't really have this file on my PC.

Moreover, I can ignore WebStorm error about incorrect configuration and it still will work correctly but in this case I have to press 'OK' everytime I restart my debugging session to ignore this error.
Of course I also can create dummy dist/main.js file in my project on my PC so WebStorm doesn't complain about it but I guess there should be an option to select remote file if you use remote Node interpreter.

2 comments
Comment actions Permalink

You are debugging a local app, with remote interpreter you can map your locally available app you have set breakpoints in to a remote app run in VM. That's why you need specifying a local files in your configuration, remote ones will be found using mappings

1
Comment actions Permalink

Oh okay. Seems like I misunderstood how it works.

 

0

Please sign in to leave a comment.