summaryrefslogtreecommitdiff
path: root/debootstrap.sh
diff options
context:
space:
mode:
authorAndrew Cady <d@jerkface.net>2018-06-12 11:37:43 -0400
committerAndrew Cady <d@jerkface.net>2018-06-13 17:13:52 -0400
commit93218b372997b30ee19f6bfe14172815846b2566 (patch)
tree07c3d20c5ec852a410f837152219ad3fe4b26a61 /debootstrap.sh
parentda3dc476af372e0ff02a6f8bdc4147e549268388 (diff)
use variable for default chroot command
Diffstat (limited to 'debootstrap.sh')
-rwxr-xr-xdebootstrap.sh4
1 files changed, 3 insertions, 1 deletions
diff --git a/debootstrap.sh b/debootstrap.sh
index c0554ad..913bc66 100755
--- a/debootstrap.sh
+++ b/debootstrap.sh
@@ -156,12 +156,14 @@ sh_image()
156 return $r 156 return $r
157} 157}
158 158
159default_chroot_command=/bin/bash
160
159chroot_image() 161chroot_image()
160{ 162{
161 suite=$1 163 suite=$1
162 name=$2 164 name=$2
163 shift 2 165 shift 2
164 [ $# = 0 ] && set -- /bin/bash 166 [ $# -gt 0 ] || set -- $default_chroot_command
165 set -- \ 167 set -- \
166 unshare -f -m -p \ 168 unshare -f -m -p \
167 chroot . \ 169 chroot . \