1

Not sure what happened, but up until last week, I've been able to clone git repositories via SSH-based URIs in my Windows containers based on the dotnet-framework-docker container. Now, suddenly without warning, when I go to clone - even a public repository, I get this error:

C:\>git clone git@github.com:atrauzzi/praxis.git
git clone git@github.com:atrauzzi/praxis.git
Cloning into 'praxis'...
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

Here's a simple Dockerfile that can be used to reproduce the issue:

FROM microsoft/dotnet-framework
SHELL ["powershell"]

# Install Git
RUN New-Item -ItemType Directory -Force -Path 'c:/git';
RUN Invoke-WebRequest "https://github.com/git-for-windows/git/releases/download/v2.15.1.windows.1/Git-2.15.1-64-bit.exe" -OutFile "/git-installer.exe" -UseBasicParsing;
RUN Start-Process -FilePath C:/git-installer.exe -ArgumentList '/VERYSILENT', '/NORESTART', '/NOCANCEL', '/SP-', '/DIR="c:/git"' -PassThru | Wait-Process;
RUN rm /git-installer.exe;

I'm not sure at this point what could be causing this. The only suspicious thing is that if I try to run the mingw based ssh.exe, it prints a blank line and then exits.

Some suspicions I have are obviously around mingw and the fact that I'm running things in a container.

cc https://github.com/Microsoft/dotnet-framework-docker/issues/61

1

This is just a guess - but I suspect that the dotnet framework image used to have the SSH key for GitHub already... That said looking into https://github.com/git-for-windows/git/issues/1403 as the root/ideal fix.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.