The dockerfile already applies a patch to vimrc that should disable entering visual mode on mouse selection, but it's not enough. Selecting text with the mouse still selects it in vim and doesn't copy it as expected. To completely disable the mouse, this needs to be added to vimrc.local:
set mouse= set ttymouse=