Visual Studio Code docker extenstion updated to containers. now no debugging

Hi, I’m the Toradex AI Assistant.

I might make mistakes. Our support team will step in if needed. If I answered your question, please tick the “Solution” checkbox. For follow-up questions to me, please use @ToradexAI in your post.

Did you like my answer? :+1: :-1:


Hello! Thank you for sharing such a detailed overview of your situation and the troubleshooting steps you’ve already taken. The error message you are encountering:

Get "http://192.168.63.2:5002/v2/": net/http: request canceled while waiting for connection (Client.Timeout exceeded while awaiting headers)

indicates a connectivity or configuration issue between Docker on your development machine and your local registry. Let’s go through a step-by-step checklist to help restore container registry access.


1. Check Local Registry Binding and Port

You mentioned starting your registry with:

docker run -d -p 5002:5000 --restart=always --name registry registry:2

However, this maps port 5000 inside the container to 5002 on the host. Make sure your configuration and access commands are consistent. Standard practice is to use the same port both inside and outside, like so:

docker run -d -p 5002:5002 --restart=always --name registry -e REGISTRY_HTTP_ADDR=0.0.0.0:5002 registry:2

This ensures the registry listens on all interfaces using port 5002 (reference).


2. Mark Registry as Insecure (if using HTTP)

If your registry is HTTP (not HTTPS), Docker won’t connect unless you explicitly mark it as an insecure registry. Add or update your /etc/docker/daemon.json file to include:

{
  "insecure-registries" : ["192.168.63.2:5002"]
}

(reference)

After editing this file, restart Docker:

sudo systemctl restart docker

3. Test Registry Connectivity

On your development machine, try:

curl http://192.168.63.2:5002/v2/

A successful response will be {}. If there’s no response or you see an error, the registry isn’t reachable (reference).

If you’re running on Windows with WSL2, also ensure your firewall allows inbound connections on port 5002.


4. Validate Docker Configuration and Network

  • Double-check your project’s docker-compose or related files to ensure they are referencing the correct registry and image tags.
  • Make sure there are no leftover containers or misconfigurations from old sessions which may conflict.

5. Update Registry Address in Project/VS Code

Make sure any project settings or environment variables referencing the registry (e.g., LOCAL_REGISTRY) match the correct IP and port.


6. Other Troubleshooting Steps

  • Try stopping and removing the registry, then starting it with the correct command.

    docker stop registry && docker rm registry
    docker run -d -p 5002:5002 --restart=always --name registry -e REGISTRY_HTTP_ADDR=0.0.0.0:5002 registry:2
    
  • Consider clearing Docker’s cache of old images or containers if updates have occurred.


If after following these steps you’re still having issues, let me know specific results, especially from the curl test and checking your daemon.json. That will help narrow down if it’s truly a connectivity problem, or possibly a deeper Docker/VS Code integration issue.

Additional Resources:

Best regards,
Toradex AI Assistant.