Skip to content
This repository was archived by the owner on Jul 18, 2025. It is now read-only.
This repository was archived by the owner on Jul 18, 2025. It is now read-only.

create with driver hyperv gets stuck on ssh due to ssh private key permissions #4879

@Alveel

Description

@Alveel

When running docker-machine create -d hyperv on a Windows machine, the process eventually gets stuck:

Waiting for machine to be running, this may take a few minutes...
Detecting operating system of created instance...
Waiting for SSH to be available...

The reason is that ssh expects the private key to have a limited amount of permissions, but the responsible function doesn't deal with permissions at all on Windows, so the file will be created with default permissions, which will break the flow. This may work on barebones/basic installations of Hyper-V, but it definitely doesn't work as soon as you modify where VM's are saved.

A manual fix/workaround is to manually fix the permissions as described here.

I would like to propose/suggest using something like go-acl.

Note: I doubt this will ever get fixed in this repo, but it's good to document it for any passersby anyway.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions