summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2021-04-11 14:36:05 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2021-04-11 14:40:12 +0000
commit2d44f002c25cff5905099a3c4027b0c3e3ad4a2e (patch)
tree74279e25ec555e1eaef85fd11cd99070809c9f98
parentImproving variable usage to shorten strings in rules. (diff)
downloadopen-infrastructure-compute-tools-2d44f002c25cff5905099a3c4027b0c3e3ad4a2e.tar.xz
open-infrastructure-compute-tools-2d44f002c25cff5905099a3c4027b0c3e3ad4a2e.zip
Using which to check for commands in maintainer script to avoid lintian 'command-with-path'-warning.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
-rw-r--r--debian/open-infrastructure-container-tools.config2
-rwxr-xr-xdebian/open-infrastructure-container-tools.postinst2
2 files changed, 2 insertions, 2 deletions
diff --git a/debian/open-infrastructure-container-tools.config b/debian/open-infrastructure-container-tools.config
index 0c694fa..514d1bb 100644
--- a/debian/open-infrastructure-container-tools.config
+++ b/debian/open-infrastructure-container-tools.config
@@ -35,7 +35,7 @@ then
SCRIPT_CHOICES="$(cd /usr/share/compute-tools/scripts && find -maxdepth 1 -not -type d -and -not -name 'default' -and -not -name 'debconf' -and -not -name '*.d' -printf '%P\n' | sort)"
db_subst open-infrastructure-container-tools/script SCRIPT_CHOICES "$(echo ${SCRIPT_CHOICES} | sed -e 's| |, |g')"
- if [ -x /usr/bin/lsb_release ]
+ if [ -x "$(which lsb_release)" ]
then
DISTRIBUTOR="$(lsb_release -is 2>/dev/null)"
fi
diff --git a/debian/open-infrastructure-container-tools.postinst b/debian/open-infrastructure-container-tools.postinst
index 1cac16a..44d0582 100755
--- a/debian/open-infrastructure-container-tools.postinst
+++ b/debian/open-infrastructure-container-tools.postinst
@@ -108,7 +108,7 @@ EOF
mv -f "${CONFFILE}.tmp" "${CONFFILE}"
- if [ -x /sbin/sysctl ]
+ if [ -x "$(which sysctl)" ]
then
sysctl -q -p /etc/sysctl.d/zz-container.conf
fi