nproc

Print the number of processing units (normally CPUs) available. More information: <https://www.gnu.org/software/coreutils/nproc>.

Debian Debian
RUN apt-get update && \ apt-get install -y coreutils
Ubuntu
RUN apt-get update && \ apt-get install -y coreutils
Alpine
RUN apk add coreutils
Arch Arch Linux
RUN pacman -S --noconfirm coreutils
image/svg+xml Kali Linux
RUN apt-get update && \ apt-get install -y coreutils
CentOS
RUN yum install -y coreutils
Fedora
RUN dnf install -y coreutils
Raspbian
RUN apt-get update && \ apt-get install -y coreutils
click the source code to copy install nproc on any operating system with command-not-found.com