Home > Enterprise >  How do I set up PhpStorm/WebStorm to work with Node.js in a docker container?
How do I set up PhpStorm/WebStorm to work with Node.js in a docker container?

Time:04-10

I am trying to use PhpStorm to debug as Node application that is running in a docker container. The image is called parsoid-dev, it only exists locally on my machine. I can run it using docker run parsoid-dev.

In the PhpStorm settings, I created a remote Node.js interpreter configuration for this image using the server type "Docker", image "parsoid-dev", and path "node".

node.js interpreter settings dialog

But when I try to run the application, I get this error:

Failed to prepare environment: Cannot find image: parsoid-dev

But the image is clearly there, I can use it from the command line... What am I missing?

EDIT: I'm using PhpStorm 2021.3.3 on Windows 11 and Docker for Windows 4.6.0 (Docker Desktop engine 20.10.13). I'm running Ubuntu 20.04.4 in WSL2.

CodePudding user response:

Please try specifying the image name with a tag, e.g. parsoid-dev:latest - does it help?

  • Related