mirror of
https://github.com/pi-hole/pi-hole.git
synced 2024-11-15 02:42:58 +00:00
Merge pull request #2646 from pi-hole/fix/FTL_arch_detect_rpm
Don't fail when trying to detect OS architecture on RPM-based systems
This commit is contained in:
commit
5950b4bb78
1 changed files with 3 additions and 1 deletions
|
@ -2294,10 +2294,12 @@ get_binary_name() {
|
|||
elif [[ "${machine}" == "x86_64" ]]; then
|
||||
# This gives the architecture of packages dpkg installs (for example, "i386")
|
||||
local dpkgarch
|
||||
dpkgarch=$(dpkg --print-architecture 2> /dev/null)
|
||||
dpkgarch=$(dpkg --print-architecture 2> /dev/null || true)
|
||||
|
||||
# Special case: This is a 32 bit OS, installed on a 64 bit machine
|
||||
# -> change machine architecture to download the 32 bit executable
|
||||
# We only check this for Debian-based systems as this has been an issue
|
||||
# in the past (see https://github.com/pi-hole/pi-hole/pull/2004)
|
||||
if [[ "${dpkgarch}" == "i386" ]]; then
|
||||
printf "%b %b Detected 32bit (i686) architecture\\n" "${OVER}" "${TICK}"
|
||||
binary="pihole-FTL-linux-x86_32"
|
||||
|
|
Loading…
Reference in a new issue