From patchwork Fri Jan 20 12:19:02 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ian Jackson X-Patchwork-Id: 9528149 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 52E2A60459 for ; Fri, 20 Jan 2017 12:23:01 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4454328560 for ; Fri, 20 Jan 2017 12:23:01 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 385582861F; Fri, 20 Jan 2017 12:23:01 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id C9FEB28616 for ; Fri, 20 Jan 2017 12:23:00 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cUYBi-0000oT-V0; Fri, 20 Jan 2017 12:21:02 +0000 Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cUYBh-0000mu-6K for xen-devel@lists.xenproject.org; Fri, 20 Jan 2017 12:21:01 +0000 Received: from [85.158.139.211] by server-7.bemta-5.messagelabs.com id CF/56-29113-CA002885; Fri, 20 Jan 2017 12:21:00 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFuplkeJIrShJLcpLzFFi42JxWrohUncFQ1O EwcqzBhbft0xmcmD0OPzhCksAYxRrZl5SfkUCa8azT1/YCw6zVuw6/Z2tgfEOSxcjB4eEgL/E tTeSXYycHGwCuhJNW/6ygYRFBFQkbu81ADGZBUIldrywBKkQFkiVWPRxKiOIzSKgKnH/5142E JtXwEti+5K1LCC2hICcxPnjP5lBbE6g+IbObWC2kICnROOfn4wgI4UE1CTmro+HaBWUODnzCV grs4CExMEXL5gnMPLOQpKahSS1gJFpFaNGcWpRWWqRrqGJXlJRZnpGSW5iZo6uoYGpXm5qcXF iempOYlKxXnJ+7iZGYNAwAMEOxrOnPQ8xSnIwKYny7v7YECHEl5SfUpmRWJwRX1Sak1p8iFGG g0NJgvfjv8YIIcGi1PTUirTMHGD4wqQlOHiURHhD/gOleYsLEnOLM9MhUqcYdTlOfbrwkkmIJ S8/L1VKnPcFyAwBkKKM0jy4EbBYusQoKyXMywh0lBBPQWpRbmYJqvwrRnEORiVhXm+QVTyZeS Vwm14BHcEEdISVcj3IESWJCCmpBsaAgr9P2zcZfrzz+CrbhyUP8gIzVadu+zXH3ydQ+l9viav o93PbBTimv73zJC0o7tm99X+feWyebrkm6OQUC1bOuM3WMhbzukvvGc78JxQr/bfyi1/jTr+T LbJVsz6ZXD0a4n+w2k33uNWyGcZqK1tdF8jK3J+fvmt5kcMR5uTr+UudXARe5SsrsRRnJBpqM RcVJwIAnMGzeKACAAA= X-Env-Sender: prvs=18694997c=Ian.Jackson@citrix.com X-Msg-Ref: server-13.tower-206.messagelabs.com!1484914855!65401821!1 X-Originating-IP: [66.165.176.89] X-SpamReason: No, hits=0.0 required=7.0 tests=sa_preprocessor: VHJ1c3RlZCBJUDogNjYuMTY1LjE3Ni44OSA9PiAyMDMwMDc=\n, received_headers: No Received headers X-StarScan-Received: X-StarScan-Version: 9.1.1; banners=-,-,- X-VirusChecked: Checked Received: (qmail 21464 invoked from network); 20 Jan 2017 12:20:56 -0000 Received: from smtp.citrix.com (HELO SMTP.CITRIX.COM) (66.165.176.89) by server-13.tower-206.messagelabs.com with RC4-SHA encrypted SMTP; 20 Jan 2017 12:20:56 -0000 X-IronPort-AV: E=Sophos;i="5.33,258,1477958400"; d="scan'208";a="400967846" From: Ian Jackson To: Date: Fri, 20 Jan 2017 12:19:02 +0000 Message-ID: <1484914764-20861-14-git-send-email-ian.jackson@eu.citrix.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1484914764-20861-1-git-send-email-ian.jackson@eu.citrix.com> References: <1484914764-20861-1-git-send-email-ian.jackson@eu.citrix.com> MIME-Version: 1.0 Cc: Ian Jackson Subject: [Xen-devel] [OSSTEST PATCH 13/35] d-i: Cope if .ssh already exists (in /target/root/ and also /home/...) X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" X-Virus-Scanned: ClamAV using ClamSMTP Use mkdir -p in both cases. Otherwise these late_commands may fail. Signed-off-by: Ian Jackson --- Osstest/Debian.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Osstest/Debian.pm b/Osstest/Debian.pm index dacefb3..987c7c6 100644 --- a/Osstest/Debian.pm +++ b/Osstest/Debian.pm @@ -735,13 +735,13 @@ r=/target/root cd \$r umask 022 -mkdir .ssh +mkdir -p .ssh $preseed_wget -O .ssh/authorized_keys '$authkeys_url' $preseed_wget -O .ssh/known_hosts '$knownhosts_url' u=osstest h=/home/\$u -mkdir /target\$h/.ssh +mkdir -p /target\$h/.ssh cp .ssh/authorized_keys /target\$h/.ssh chroot /target chown -R \$u.\$u \$h/.ssh END