1
0
Fork 0
mirror of https://github.com/mlocati/docker-php-extension-installer synced 2025-05-08 16:17:20 +00:00

Add support for predefined processor count (#809)

This commit is contained in:
Ramūnas Dronga 2023-10-09 11:25:38 +03:00 committed by GitHub
parent 023145989d
commit 2ff0feb4cf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 0 deletions

View file

@ -1624,6 +1624,10 @@ expandInstalledSystemPackageName() {
# Output:
# The number of processor cores available
getProcessorCount() {
if test -n "${IPE_PROCESSOR_COUNT:-}"; then
echo $IPE_PROCESSOR_COUNT
return
fi
if command -v nproc >/dev/null 2>&1; then
nproc
else