templates/*.in: fixed PATH handling with spaces

if $PATH already contains a path with a space the append of the
default directories in all template scripts fails with an error
like the following:

/usr/share/lxc/templates/lxc-download: 69: export: (x86)/NVIDIA: bad
variable name

Signed-off-by: Christian Ratzenhofer <christian.ratzenhofer@cdnm.at>
This commit is contained in:
Christian Ratzenhofer 2021-04-06 14:39:11 +02:00
parent 093bfcc83c
commit 655d10ed7f
4 changed files with 4 additions and 4 deletions

View File

@ -26,7 +26,7 @@ LXC_MAPPED_GID=
BUSYBOX_EXE=`which busybox` BUSYBOX_EXE=`which busybox`
# Make sure the usual locations are in PATH # Make sure the usual locations are in PATH
export PATH=$PATH:/usr/sbin:/usr/bin:/sbin:/bin export PATH="$PATH:/usr/sbin:/usr/bin:/sbin:/bin"
in_userns() { in_userns() {
[ -e /proc/self/uid_map ] || { echo no; return; } [ -e /proc/self/uid_map ] || { echo no; return; }

View File

@ -66,7 +66,7 @@ if [ -z "${DOWNLOAD_KEYSERVER:-}" ]; then
fi fi
# Make sure the usual locations are in PATH # Make sure the usual locations are in PATH
export PATH=$PATH:/usr/sbin:/usr/bin:/sbin:/bin export PATH="$PATH:/usr/sbin:/usr/bin:/sbin:/bin"
# Some useful functions # Some useful functions
cleanup() { cleanup() {

View File

@ -33,7 +33,7 @@ MODE="system"
COMPAT_LEVEL=5 COMPAT_LEVEL=5
# Make sure the usual locations are in PATH # Make sure the usual locations are in PATH
export PATH=$PATH:/usr/sbin:/usr/bin:/sbin:/bin export PATH="$PATH:/usr/sbin:/usr/bin:/sbin:/bin"
in_userns() { in_userns() {
[ -e /proc/self/uid_map ] || { echo no; return; } [ -e /proc/self/uid_map ] || { echo no; return; }

View File

@ -23,7 +23,7 @@
set -eu set -eu
# Make sure the usual locations are in PATH # Make sure the usual locations are in PATH
export PATH=$PATH:/usr/sbin:/usr/bin:/sbin:/bin export PATH="$PATH:/usr/sbin:/usr/bin:/sbin:/bin"
# Check for required binaries # Check for required binaries
for bin in skopeo umoci jq; do for bin in skopeo umoci jq; do