mirror of
git://github.com/lxc/lxc
synced 2025-09-02 23:19:48 +00:00
lxc-download: Fix to work without mktemp
mktemp isn't always available in busybox. Signed-off-by: Stéphane Graber <stgraber@ubuntu.com>
This commit is contained in:
@@ -249,7 +249,13 @@ fi
|
|||||||
|
|
||||||
# Trap all exit signals
|
# Trap all exit signals
|
||||||
trap cleanup EXIT HUP INT TERM
|
trap cleanup EXIT HUP INT TERM
|
||||||
|
|
||||||
|
if ! type mktemp >/dev/null 2>&1; then
|
||||||
|
DOWNLOAD_TEMP=/tmp/lxc-download.$$
|
||||||
|
mkdir -p $DOWNLOAD_TEMP
|
||||||
|
else
|
||||||
DOWNLOAD_TEMP=$(mktemp -d)
|
DOWNLOAD_TEMP=$(mktemp -d)
|
||||||
|
fi
|
||||||
|
|
||||||
# Simply list images
|
# Simply list images
|
||||||
if [ "$DOWNLOAD_LIST_IMAGES" = "true" ] || \
|
if [ "$DOWNLOAD_LIST_IMAGES" = "true" ] || \
|
||||||
|
Reference in New Issue
Block a user