I am suffering the same issue running Jenkins (which uses Git) inside a Docker container. This used to work for me but it stopped after some Git update so I compared few version and I noticed that last version that worked inside a container was 2.11.1.
Here is the proof - C:\temp is mounted from docker host:
06/06/2017 04:44 PM <SYMLINKD> temp [\\?\ContainerMappedDirectories\3090B08B-4EA2-49CB-8C30-227E982EC311]
Attempt with 2.11.1:
PS C:\Program Files\git\bin> .\git.exe --version
git version 2.11.1.windows.1
PS C:\Program Files\git\bin> .\git.exe init C:\temp\git11.1\
Initialized empty Git repository in C:/temp/git11.1/.git/
Attempt with 2.12.1:
PS C:\Program Files\Git\bin> .\git.exe --version
git version 2.12.1.windows.1
PS C:\Program Files\Git\bin> .\git.exe init C:\temp\git12.1\
fatal: Invalid path '/ContainerMappedDirectories': No such file or directory
Same with MinGit:
PS C:\> .\Min\MinGit-2.13.0-64-bit\cmd\git.exe init C:\temp\MinGitRepo\
fatal: Invalid path '/ContainerMappedDirectories': No such file or directory
PS C:\> .\Min\MinGit-2.11.1-64-bit\cmd\git.exe init C:\temp\MinGitRepo\
Initialized empty Git repository in C:/temp/MinGitRepo/.git/
Hard to say what changed, I'll take a deep dive into Git changelog, as for now using 2.11.1 seems like a decent workaround for me. Let me know if it worked for you.