Dockerfile fails more cleanly if .git is a submodule
#3591
Merged
Dockerfile fails more cleanly if .git is a submodule
#3591