From 47e806d785e3195f855584d0739abb0ee2682c27 Mon Sep 17 00:00:00 2001 From: =?utf8?q?H=C3=A9ctor=20Or=C3=B3n=20Mart=C3=ADnez?= Date: Mon, 30 Jan 2017 11:51:07 +0100 Subject: [PATCH] setup-dchroot: create /srv/chroot MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Usually when new buildd is setup it does not have a basedir (/srv/chroot) which causes script setting up build chroots to fail. This change creates basedir if directory does not exist, instead to error out. Signed-off-by: Héctor Orón Martínez --- modules/schroot/files/setup-dchroot | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/schroot/files/setup-dchroot b/modules/schroot/files/setup-dchroot index c1350cdbf..d6275b55d 100755 --- a/modules/schroot/files/setup-dchroot +++ b/modules/schroot/files/setup-dchroot @@ -294,7 +294,7 @@ if [ -z "${builddir:-}" ]; then fi done fi -[ -d "$basedir" ] || die "Error: $basedir does not exist (or is not a directory)." +[ -d "$basedir" ] || mkdir -p "$basedir" [ -d "$builddir" ] || die "Error: $builddir does not exist (or is not a directory)." target="$basedir/$tuple.tar.gz" -- 2.20.1