A sandbox for experimenting with docker.
- Start the application in debug mode (note the use of a
debug
docker-compose file) - Identify a component (golang-service, node-service, react-web-app, etc) that you'd like to debug
- Add breakpoints in VSCode
- Launch "Attach to component" (from VSCode's
Run and Debug
view) - Use the application so that it triggers the breakpoints
# Start and use the application in debug mode
> docker compose -f "docker-compose.debug.yml" up -d --build
> curl localhost:3000
# Stop the application
> docker compose -f "docker-compose.debug.yml" down
# Start and use the application
> docker compose -f "docker-compose.yml" up -d --build
> curl localhost:3000
# Stop the application
> docker compose -f "docker-compose.yml" down