Limiting the no. of CPUs the container can see


Is there any way that i can limit the no. of cpus visible to the container?
I tried using the --cpuset-cpus set option, but the container is still seeing all the cpus of the host.
Any advise is appreciated

I have exactly the same questions!

I’m talking about visibility that htop still sees all CPUs regardless of “usable” ones.

I’m running a super computer and allow users to use containers. These users shouldn’t see how powerful this super computer is, nor the total number of installed CPUs.