Message ID | 20241017075727.101424-1-amikan@ilbers.de |
---|---|
State | Accepted, archived |
Headers | show
Return-Path: <isar-users+bncBCHIPONZWECRB5UGYO4AMGQEW2YTGKA@googlegroups.com> Received: from shymkent.ilbers.de ([unix socket]) by shymkent (Cyrus 2.5.10-Debian-2.5.10-3+deb9u2) with LMTPA; Thu, 17 Oct 2024 09:58:00 +0200 X-Sieve: CMU Sieve 2.4 Received: from mail-qt1-f183.google.com (mail-qt1-f183.google.com [209.85.160.183]) by shymkent.ilbers.de (8.15.2/8.15.2/Debian-8+deb9u1) with ESMTPS id 49H7vmIS009457 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for <iupwgm@isar-build.org>; Thu, 17 Oct 2024 09:57:49 +0200 Received: by mail-qt1-f183.google.com with SMTP id d75a77b69052e-4609594e306sf21561951cf.0 for <iupwgm@isar-build.org>; Thu, 17 Oct 2024 00:57:49 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1729151863; cv=pass; d=google.com; s=arc-20240605; b=EX0zuWME8pBFf9sxYuOfvRpB2f9thAuldR2oMK4441QALRK7j7pFl2nPLEiS41COLR /vWc7HfDLPeNEz05OqndIbhLqv9MfQDSi8UOk5giD2tftc7Gvpgvz63Lau0IVaUkovRL CswLy7hqzadFm3/F9wupXWvRirAFq9LRp0CfLsTqLal803DnNaeOMFsvrJSWh9wcByxV 1BFJgsRHiGgvAyAMoDxzR9BjMtpuIkCUYeXdHUlIpMxM7D1mME5jdRpuDd2UpX8v7XSL ecyDNdWIfy7J3vRHxJz8eLQL2LUzo8xuIJMUMaU9yiZ/DUHCufKGnlq1suvF37uy6/eQ 3msw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:mime-version:message-id:date :subject:cc:to:from:sender:dkim-signature; bh=ItpXAZdYjHgOLaX4fkFCTaOdKiTVbAW9Jd8CVCdX3iE=; fh=rUXbszsUWtGyM5uN5BYuEUhrhVTJUSeGkiHb6ZVCh34=; b=dKYP+nD8R/0oixmIS9pc9bTGU08u3My/7tNooqFssLwiI7TWaQPFHPyZL2XS8QWr9u XErb4lvBpcwlIHn4NWNqiyfcGNhgKDEh7Q+lg25od1qV+xUzVEWqurov+qtqTnSJR/QC +iIu1PI2ZOQjbrZeaIz1bemeY+75LWMXYJjMjqeOfNDqKLUEPsSlracQkKazpZVCvAyV W5bCbY0srbXpEKx0s3hsB6ypO6k4YErfRfI9Bna2gQEArhbVuaoJ1XwO1uuaZrNans7t yvlt6v7H+SKfqZdlRDzdzN1YM819rBfmnS2atYWm/EwM3WHcia2hVHav12Yh3O0rVQAe kBig==; darn=isar-build.org ARC-Authentication-Results: i=2; gmr-mx.google.com; spf=pass (google.com: domain of amikan@ilbers.de designates 85.214.156.166 as permitted sender) smtp.mailfrom=amikan@ilbers.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20230601; t=1729151863; x=1729756663; darn=isar-build.org; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:x-original-authentication-results :x-original-sender:mime-version:message-id:date:subject:cc:to:from :sender:from:to:cc:subject:date:message-id:reply-to; bh=ItpXAZdYjHgOLaX4fkFCTaOdKiTVbAW9Jd8CVCdX3iE=; b=QVjXdrWQV4e71/r7ZV9dbqvPWEwUakrIKI4dclqlA/9x88NbhoNUkyFlxARmKg581X bQJJePg9x/bLXismRbLg39o+O2EF3b0PzirjkNy/lszbFBx06WQg3cONZ42MtXvQGYf8 qLrWONq+3OQh4uRt7rr8L1Vz4vs4H+aDLW8A8B+NHKOCsyOguQGUhWK10VUyoc7CCP0F mgBoaP2MGEeIhWwzBh5EjQHZ56sbby7YAqmendslr/jkbivTQESHgWErDKtl/F/Y25h3 pAM7/uIm3cvsrQXcrKYhXTmgO2MS69nPZ1hMmOLvRqAGjRdsQI50wBasqJZFbKk8sbdL D3Tw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729151863; x=1729756663; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence :x-original-authentication-results:x-original-sender:mime-version :message-id:date:subject:cc:to:from:x-beenthere:x-gm-message-state :sender:from:to:cc:subject:date:message-id:reply-to; bh=ItpXAZdYjHgOLaX4fkFCTaOdKiTVbAW9Jd8CVCdX3iE=; b=RImvWmBmykpPXmX7pWiWN1fbzUgHFNVuQsrXC6x2cYBr/C/+lYZJN7te1iNSJIMFJR Svr8D7qA1rIDHXV5JkMM+yDtRfOPvhNldHFldLZCsZ/i4Gm3P5yENDCDfQdMtSLHhkmN 8rTOlSc9oHkcSfufhZAVCcECCKueQ/KbLntmT6ciwtUufm+mbEoC2KpdfQPIQiIWcd3W 8gciQsCHGias/J12cGvzuuv0G8OioxNmHMjOcgYze3Zy43le6yXc5n6uIDwsAvaLWfo7 GsbabnAHmaYvWSsUuUWxlfhIN6cjTFslGTyHFV0LkLH6iBc+cRSuXd1jcVx7JsXmWQn7 iL1g== Sender: isar-users@googlegroups.com X-Forwarded-Encrypted: i=2; AJvYcCXKIUhimtMmeKCIolIruZRIFWD0VmpZxTB6UyWipeV7ucKmzxUFemRd1AhhMrL3dPtz5/qLrss=@isar-build.org X-Gm-Message-State: AOJu0Yw7syBPBVIf6inCA26Qd0h6P5FSOkPEr+uWlN+FLKMtcZvaMqtq pkDQ2F6LtD0LHY6AMlUR8VrpFVDF7ep3k3v0/Xe76lueP9XPC9Cn X-Google-Smtp-Source: AGHT+IFsO5keB4x9LwW6zJd9HfztCypm3aJLVuolo25vya+ikpytt8KVDNLv7a+SCEpkuSEJFUiCBQ== X-Received: by 2002:a05:622a:251b:b0:45b:3473:870d with SMTP id d75a77b69052e-4609b5ffd11mr40181641cf.26.1729151863079; Thu, 17 Oct 2024 00:57:43 -0700 (PDT) X-BeenThere: isar-users@googlegroups.com Received: by 2002:a05:622a:41:b0:458:3f09:c712 with SMTP id d75a77b69052e-4609b47da7fls7954781cf.0.-pod-prod-00-us; Thu, 17 Oct 2024 00:57:42 -0700 (PDT) X-Received: by 2002:a05:620a:3189:b0:7b1:4778:1564 with SMTP id af79cd13be357-7b14d4e39demr404574285a.3.1729151862422; Thu, 17 Oct 2024 00:57:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1729151862; cv=none; d=google.com; s=arc-20240605; b=YYb8xUmM3TiUFBeOzU+/QVRuSsDYwfNJPe6Oh/RUtMQd//l2sZtumkh0HHRDFGDQKa lgOtOY0Zv9VUr23Okp56UkU0Grj7MWhhfMACENxt90vAf8HR4ydNqlkOLFVys/l9vpcp pazmlAy5I1+igKqUt5HhRItIvtBXa3VtAJdohzZ42Bv/RjI1bk2MOoyewrRDJ42wRPs3 HuCwQLDNSF1JAqno6azWXxWAkxT6WdvY9ZkG1pcuKJQ/uYGOeXy+bxVsOAJDREdGavEn J9D5DAKKfmNR8lKWdG2z3onzE1nxIEx+6zIdEJVYtzUSGWI8T9yMHnnFnz1XP7+HVIwT 9VzA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from; bh=GFZH7kR9JU8d4Hn7q+xfqrbvyZM0tx3djBv8XmYU3KI=; fh=/h9QQkzJ8EboVkWg45aWwpaUro6WMavIVd2OhN45RtE=; b=efSMz1lM7M8cN8AUw/yX5QcOjTnyS5mUqDfUaPK86gpmJdpVrCLpKzcyM/MxrI+j7e J3G6vZtDxUxSYLoEsqGSUaw/npZjyo32JByEQsC0VHh6oTG8nzu6OadQPe6at8BW49Kl +sc2OLqaYlYAjTbb9zxjKB6vy1oN44ahCfaMoMO/HuorWRfxipULHMvQd5/+HC+2R9Vo 1g9UtCEenfnprlPQNuyazPBk53RKAu8jS03uAIpPz4N3KfQW5uxTwbrVTBdbaGzvHAyA G1KLHfYUNvSxBP1ixGbZFawMVov1uCDW3LtsAHrPbUsjs4WqDHP3uoB+XTlRTOcSqMjo vKEg==; dara=google.com ARC-Authentication-Results: i=1; gmr-mx.google.com; spf=pass (google.com: domain of amikan@ilbers.de designates 85.214.156.166 as permitted sender) smtp.mailfrom=amikan@ilbers.de Received: from shymkent.ilbers.de (shymkent.ilbers.de. [85.214.156.166]) by gmr-mx.google.com with ESMTPS id d75a77b69052e-4609a871ecesi783221cf.0.2024.10.17.00.57.41 for <isar-users@googlegroups.com> (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Thu, 17 Oct 2024 00:57:42 -0700 (PDT) Received-SPF: pass (google.com: domain of amikan@ilbers.de designates 85.214.156.166 as permitted sender) client-ip=85.214.156.166; Received: from user-B660.promwad.corp ([159.148.83.114]) (authenticated bits=0) by shymkent.ilbers.de (8.15.2/8.15.2/Debian-8+deb9u1) with ESMTPSA id 49H7vZkI009442 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 17 Oct 2024 09:57:35 +0200 From: Anton Mikanovich <amikan@ilbers.de> To: isar-users@googlegroups.com Cc: Anton Mikanovich <amikan@ilbers.de> Subject: [PATCH] deb-dl-dir: Avoid hanging mounts on failed download Date: Thu, 17 Oct 2024 10:57:27 +0300 Message-Id: <20241017075727.101424-1-amikan@ilbers.de> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-Spam-Status: No, score=-4.6 required=5.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_EF,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED,RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL,RCVD_IN_RP_CERTIFIED,RCVD_IN_RP_RNBL,RCVD_IN_RP_SAFE, SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on shymkent.ilbers.de X-Original-Sender: amikan@ilbers.de X-Original-Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of amikan@ilbers.de designates 85.214.156.166 as permitted sender) smtp.mailfrom=amikan@ilbers.de Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list isar-users@googlegroups.com; contact isar-users+owners@googlegroups.com List-ID: <isar-users.googlegroups.com> X-Spam-Checked-In-Group: isar-users@googlegroups.com X-Google-Group-Id: 914930254986 List-Post: <https://groups.google.com/group/isar-users/post>, <mailto:isar-users@googlegroups.com> List-Help: <https://groups.google.com/support/>, <mailto:isar-users+help@googlegroups.com> List-Archive: <https://groups.google.com/group/isar-users List-Subscribe: <https://groups.google.com/group/isar-users/subscribe>, <mailto:isar-users+subscribe@googlegroups.com> List-Unsubscribe: <mailto:googlegroups-manage+914930254986+unsubscribe@googlegroups.com>, <https://groups.google.com/group/isar-users/subscribe> X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= |
Series |
deb-dl-dir: Avoid hanging mounts on failed download
|
expand
|
diff --git a/meta/classes/deb-dl-dir.bbclass b/meta/classes/deb-dl-dir.bbclass index 55e56c50..7ebd057e 100644 --- a/meta/classes/deb-dl-dir.bbclass +++ b/meta/classes/deb-dl-dir.bbclass @@ -48,6 +48,9 @@ debsrc_download() { debsrc_do_mounts "${rootfs}" + trap 'exit 1' INT HUP QUIT TERM ALRM USR1 + trap 'debsrc_undo_mounts "${rootfs}"' EXIT + ( flock 9 set -e printenv | grep -q BB_VERBOSE_LOGS && set -x
If apt-get fails during debsrc_download execution there will be mount left behind. Protect it with a trap for cleanup in case of failure. Signed-off-by: Anton Mikanovich <amikan@ilbers.de> --- meta/classes/deb-dl-dir.bbclass | 3 +++ 1 file changed, 3 insertions(+)