diff --git a/stackrc b/stackrc index 3c4e4370e8..66d6f238a5 100644 --- a/stackrc +++ b/stackrc @@ -819,11 +819,14 @@ SERVICE_GRACEFUL_SHUTDOWN_TIMEOUT=${SERVICE_GRACEFUL_SHUTDOWN_TIMEOUT:-5} # Service graceful shutdown timeout WORKER_TIMEOUT=${WORKER_TIMEOUT:-90} -# Support alternative yum -- in future Fedora 'dnf' will become the -# only supported installer, but for now 'yum' and 'dnf' are both -# available in parallel with compatible CLIs. Allow manual switching -# till we get to the point we need to handle this automatically -YUM=${YUM:-yum} +# Choose DNF on RedHat/Fedora platforms with it, or otherwise default +# to YUM. Can remove this when only dnf is supported (i.e. centos7 +# disappears) +if [[ -e /usr/bin/dnf ]]; then + YUM=${YUM:-dnf} +else + YUM=${YUM:-yum} +fi # Common Configuration # --------------------