What You'll Learn
Beginner
- How to debug Node.js and Python apps in containers
- How to attach IDE debuggers (VS Code)
docker-compose.ymlyaml
services:
api:
ports:
- 3000:3000
- 9229:9229 # Node.js debugger
command: node --inspect=0.0.0.0:9229 server.jsVS Code Dev Containers
Install the Dev Containers extension, open your project, and VS Code runs inside the container.Key Takeaways
- Expose debugger port (9229 for Node, 5678 for Python).
- Attach VS Code with
launch.json. - Use
docker compose execfor one-off commands. - VS Code Dev Containers = full IDE inside container.
Comments
Comments
Post a Comment