remote-containers extension allows you to build and run a docker image of your source.
https://www.youtube.com/watch?v=KFyRLxiRKAc&t=309s
In the devcontainer.json file, add the following 2 lines:
"forwardPorts": [3000],
"postCreateCommand": "npm install",
"containerEnv": {
"CHOKIDAR_USEPOLLING":"true"
}
Build Container
F1
remote-containers rebuild and Reopen in containers
go to terminal and npm run start. This will open the node app on port 3000 in a browser.
This is definitely a work in progress. watch the video.