Is there a way to force docker-machine to create the docker vm with a specific ip (assuming that ip is available)?
Yes, there is an option to create with specific ip. All you need to do is specify ip/ip-range with --virtualbox-hostonly-cidr option.
For example:
when you want to assign specific ip, let say you want to assign 10.15.1.24, then appropriate config will be (the most important thing is the mask that we are using here. For specific ip you need to set subnet mask to 32) :
docker-machine create --driver virtualbox --virtualbox-hostonly-cidr "10.15.1.24/32" dev
if you want to pick an ip from specific ip range, then you need to use appropriate subnet mask.