public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
* [PATCH] isar-bootstrap-helper: Purge /var/lib/apt/lists on cleanup
@ 2018-09-03 10:17 Jan Kiszka
  2018-09-04  8:56 ` Claudius Heine
  2018-09-06 20:47 ` Maxim Yu. Osipov
  0 siblings, 2 replies; 3+ messages in thread
From: Jan Kiszka @ 2018-09-03 10:17 UTC (permalink / raw)
  To: isar-users; +Cc: Claudius Heine, Alexander Smirnov

This saves dozens of MB on the target image. The user just needs to run
"apt-get update" to restore it.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---

The lowest hanging fruit for tinyfication. Base image on armhf, e.g., is
now ~100 MB.

Claudius, to my understanding, this will not break reproducibility as
--clean is only done on the final target image, not during the build,
not on the buildchroots.

 meta/classes/isar-bootstrap-helper.bbclass | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/classes/isar-bootstrap-helper.bbclass b/meta/classes/isar-bootstrap-helper.bbclass
index d45cdd7..de056c1 100644
--- a/meta/classes/isar-bootstrap-helper.bbclass
+++ b/meta/classes/isar-bootstrap-helper.bbclass
@@ -136,6 +136,6 @@ setup_root_file_system() {
         sudo -E chroot "$ROOTFSDIR" \
             /usr/bin/apt-get clean
         sudo "$ROOTFSDIR/chroot-setup.sh" "cleanup" "$ROOTFSDIR"
-        sudo rm -f "$ROOTFSDIR/chroot-setup.sh"
+        sudo rm -rf "$ROOTFSDIR/chroot-setup.sh" "$ROOTFSDIR/var/lib/apt/lists/"*
     fi
 }
-- 
2.16.4

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2018-09-06 20:47 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-09-03 10:17 [PATCH] isar-bootstrap-helper: Purge /var/lib/apt/lists on cleanup Jan Kiszka
2018-09-04  8:56 ` Claudius Heine
2018-09-06 20:47 ` Maxim Yu. Osipov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox