in general if you use linux this is no problem at all.
I'm not sure about OSX but last time I checked they still have a VM that runs the docker container inside of it so this wont work as expected.
But I'm not up to date with the current OSX-Docker implementation/integration :).