aboutsummaryrefslogtreecommitdiffstats
path: root/main/util-vserver/setup-vs-template
diff options
context:
space:
mode:
Diffstat (limited to 'main/util-vserver/setup-vs-template')
-rw-r--r--main/util-vserver/setup-vs-template5
1 files changed, 3 insertions, 2 deletions
diff --git a/main/util-vserver/setup-vs-template b/main/util-vserver/setup-vs-template
index 8ad7f3fae8..3edffa1aaa 100644
--- a/main/util-vserver/setup-vs-template
+++ b/main/util-vserver/setup-vs-template
@@ -16,8 +16,9 @@ clean_exit() {
outfile=template.tar.gz
fakeroot=
repos=
-while getopts "ho:qX:" opt; do
+while getopts "a:ho:qX:" opt; do
case "$opt" in
+ a) arch_opt="--arch $OPTARG";;
h) usage 0;;
o) outfile="$OPTARG";;
q) quiet=-q;;
@@ -32,7 +33,7 @@ fi
tmpdir=$(mktemp -d ${TMPDIR:-/tmp}/setup-vs-template-XXXXXX)
-apk add --root "$tmpdir" --initdb --keys-dir /etc/apk/keys -U \
+apk add --root "$tmpdir" --initdb --keys-dir /etc/apk/keys -U $arch_opt \
$quiet ${repos:---repositories-file /etc/apk/repositories} \
alpine-base $@ \
|| clean_exit 1