Perl -i truncates file on host-mapped volume

Performing an inplace edit with perl in a container on a file on a host-mapped volume deletes the file.

Windows 10 version 1703 (OS Build 15063.0)

Docker Version 17.06.0-ce-win18 (12627)
Channel: stable

PS C:\> mkdir -p \tmp\work
PS C:\> docker run --rm -it -v c:/tmp/work:/tmp/work ubuntu bash

container$ cd /tmp/work
container$ echo "one two" > test

PS C:\> cat \tmp\work\test
one two

container$ perl -i -p -e 's/two/three/g' test
Can't do inplace edit on test: No such file or directory.

PS C:\> cat \tmp\work\test
cat : Cannot find path 'C:\tmp\work\test' because it does not exist.

Similar to Bash on Windows issue 966: Perl deletes files when using in-place edit

See also Docker for Mac: Reproducible perl -i truncates file on host-mapped volume