RPi-Distro / pi-gen

Tool used to create the official Raspberry Pi OS images
BSD 3-Clause "New" or "Revised" License
2.52k stars 1.58k forks source link

Image size and build time drastically increased #746

Closed JavanXD closed 6 months ago

JavanXD commented 6 months ago

I am using pi-gen in an GitHub Action to build custom Raspberry PI OS pre-Installed Images.

But the difference in size and built time is drastic since changing the pi-gen GitHub tag.

git checkout 2023-02-21-raspios-bullseye --> Image had 700MB, build time using GitHub Action is 26min git checkout 2023-12-05-raspios-bookworm --> Image does have 1,2GB, build time using GitHub Action is 56min

Note that I only use the steps for the "lite" image.

STAGE_LIST='stage0 stage1 stage2 stage-honeypi'
#CLEAN=1 # if true => re-do the stages defined in STAGE_LIST
ENABLE_SSH=1
DEPLOY_COMPRESSION='zip'
USE_QCOW2=0
USE_QEMU=0

That's my config, what can I do to save time?

Or in other words, what did you change that this happend?

XECDesign commented 6 months ago

Main difference is increase of boot partition and addition of initramfs.

You can run something like git diff 2023-02-21-raspios-bullseye..2023-12-05-raspios-bookworm -- stage{0..2} export-image to take a look.