[lxc-devel] [lxc/master] make Alpine template more POSX shell friendly #1498

BegBlev on Github lxc-bot at linuxcontainers.org
Fri Apr 7 15:18:51 UTC 2017


A non-text attachment was scrubbed...
Name: not available
Type: text/x-mailbox
Size: 435 bytes
Desc: not available
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20170407/6c0a14ec/attachment.bin>
-------------- next part --------------
From 7276799bd7de7b147d4f3fed62ee30917dc22c3a Mon Sep 17 00:00:00 2001
From: Vincent Catros <vincent.catros at laposte.net>
Date: Fri, 7 Apr 2017 17:14:44 +0200
Subject: [PATCH] avoid assigning  to a variable which is not POSIX shell proof
 (bug #1498)

Signed-off-by: Vincent Catros <vincent.catros at laposte.net>
---
 templates/lxc-alpine.in | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/templates/lxc-alpine.in b/templates/lxc-alpine.in
index 44173ee..1547c2c 100644
--- a/templates/lxc-alpine.in
+++ b/templates/lxc-alpine.in
@@ -263,8 +263,8 @@ install() {
 }
 
 install_packages() {
-	local arch="$1"; shift
-	local packages="$@"
+	local arch="$1"
+	local packages="$2"
 
 	$APK --arch="$arch" --root=. --keys-dir="$APK_KEYS_DIR" \
 		--update-cache --initdb add $packages


More information about the lxc-devel mailing list