9951 explained code solutions for 126 technologies


dockerHow to limit CPU for docker container


docker run -it --cpus="2.0" ubuntuctrl + c
docker run

launch docker container

-it

immediately connect to container terminal after launch

--cpus

specify amount of CPUs docker container will be allowed to use

2.0

use only 2 CPUs

ubuntu

name of the image to run container from