You need to add the address to the interface first. This is not a Docker issue, but OSX specifics. You will not be able to listen on this address also with other daemons.
if you run
sudo ifconfig lo0 add 127.0.1.2 netmask 0xffffffff
your command will work properly.
Docker does have an issue here however, and it’s the fact that you can’t port forward the same port from different IP addresses (which should be perfectly possible): Docker Beta has conflicts when mapping same port on different IPs