How to reconnect to docker instance

I’ll start from the beginning.

  1. I’ve created an Ubuntu machine with docker installed on Azure.
  2. On the top I created two docker containers, I used to connect from an old computer using docker-machine for management tasks.
  3. I’ve changed my computer, so I need to connect from the new one.
  4. I’ve added my azure subscription

However when I try the docker-machine cdmdlet to the existing container I have the following error message:

  • Can't change repo in discourse docker
  • Cleanup disk space occupied by Docker images
  • Docker Compose not starting mongo service even main service depends on it
  • Docker Compose Link (Alias)
  • Ansible error due to GMP package version on Centos6
  • Docker not running on windows 10 error: Hardware assisted virtualization and data execution protection must be enabled in the BIOS
  • PS C:\WINDOWS\system32> docker-machine ssh vm name
    Host does not exist: "vm name".
    

    The machine is running but I’ll guess I’ll have to recreate the certificates used for the connection.

    I’ve tried the following with no luck:

    PS C:\WINDOWS\system32> docker-machine regenerate-certs vm name
    Regenerate TLS machine certs?  Warning: this is irreversible. (y/n): y
    Regenerating TLS certificates
    Host does not exist: "vm name"
    

    I no longer have access to the old machine.

    Has anyone been into the same situation?
    Any thoughts are welcome.

  • Gogits do not start as docker container
  • Can't install s3fs-fuse(yum fuse-devel version issue) and can't install libfuse(./config missing issue)
  • Vagrant box and Docker provider: Titan and Kafka
  • Docker Service Update Error: EOF
  • Can I make memory savings with docker by using a common image?
  • Docker-compose on Windows 7: how to import a db dump when using a yaml file?
  • One Solution collect form web for “How to reconnect to docker instance”

    You’ll have to recreate the machine using the generic driver:

    docker-machine create \
      --driver generic \
      --generic-ip-address=203.0.113.81 \
      --generic-ssh-key ~/.ssh/id_rsa \
      vm
    

    Replace the information accordingly.

    Note that this does NOT remove any data on the target instance, rather it just configures docker to talk to machine if it isn’t already, and also generates new certificates so it can communicate with the instance.

    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.