I am currently using a Macbook Pro with i7, which has 8 cores. However, I am not able set the CPU cores to more than 1. When I run
docker run --cpus=2 "my-image"
I get the following error:
docker: Error response from daemon: Range of CPUs is from 0.01 to 1.00, as there are only 1 CPUs available.
What am I missing?
You need to increase the maximum number of CPUs available to containers in the Docker Server. In OS X you can find them in Preferences -> Advanced.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With