mirror of
https://github.com/pi-hole/pi-hole.git
synced 2025-04-26 01:00:33 +00:00
Show output from failed install Issue #864
This commit is contained in:
parent
461791dddc
commit
8e0723c648
1 changed files with 5 additions and 4 deletions
|
@ -93,7 +93,7 @@ if [ -x "$(command -v apt-get)" ]; then
|
||||||
LIGHTTPD_CFG="lighttpd.conf.debian"
|
LIGHTTPD_CFG="lighttpd.conf.debian"
|
||||||
DNSMASQ_USER="dnsmasq"
|
DNSMASQ_USER="dnsmasq"
|
||||||
package_check_install() {
|
package_check_install() {
|
||||||
dpkg-query -W -f='${Status}' "${1}" 2>/dev/null | grep -c "ok installed" || ${PKG_INSTALL} "${1}"
|
${PKG_INSTALL} "${1}"
|
||||||
}
|
}
|
||||||
elif [ -x "$(command -v rpm)" ]; then
|
elif [ -x "$(command -v rpm)" ]; then
|
||||||
# Fedora Family
|
# Fedora Family
|
||||||
|
@ -668,9 +668,10 @@ install_dependent_packages() {
|
||||||
declare -a argArray1=("${!1}")
|
declare -a argArray1=("${!1}")
|
||||||
|
|
||||||
for i in "${argArray1[@]}"; do
|
for i in "${argArray1[@]}"; do
|
||||||
echo -n "::: Checking for $i..."
|
echo -n "::: Installing $i..."
|
||||||
package_check_install "${i}" &> /dev/null
|
PKG_MGR_OUT=$(package_check_install "${i}" 2>&1 ) && echo "Installed!" || (
|
||||||
echo " installed!"
|
echo "PACKAGE INSTALL ERROR" && echo "$PKG_MGR_OUT" && \
|
||||||
|
echo "::: Sometimes this can be a transitory error, check connectivity and retry" && exit 1 )
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue