diff --git a/image-recipe/_archived/build-auto-installer-iso.sh b/image-recipe/_archived/build-auto-installer-iso.sh index 75684ad6..bdcd18ed 100755 --- a/image-recipe/_archived/build-auto-installer-iso.sh +++ b/image-recipe/_archived/build-auto-installer-iso.sh @@ -1353,9 +1353,11 @@ if [ "$UNBUNDLED" = "1" ]; then # unbundled mode — their images must ride on the ISO so a fresh install # works with no internet: FileBrowser (Cloud file manager) and fmcd # (fedimint-clientd, ecash/sats out of the box). + # Shipped zstd-compressed: podman load auto-detects compression, and an + # uncompressed fmcd.tar alone added ~220MB to the ISO (RC9 size regression). CORE_BUNDLE=" -${FILEBROWSER_IMAGE} filebrowser.tar -${FMCD_IMAGE} fmcd.tar +${FILEBROWSER_IMAGE} filebrowser.tar.zst +${FMCD_IMAGE} fmcd.tar.zst " echo "$CORE_BUNDLE" | while read -r CORE_IMAGE CORE_FILE; do [ -n "$CORE_IMAGE" ] || continue @@ -1364,9 +1366,14 @@ ${FMCD_IMAGE} fmcd.tar else echo " Pulling $CORE_IMAGE ($CONTAINER_PLATFORM)..." if container_pull "$CORE_IMAGE"; then - $CONTAINER_CMD save "$CORE_IMAGE" -o "$IMAGES_DIR/$CORE_FILE" 2>/dev/null && \ - echo " ✅ Saved core: $CORE_FILE ($(du -h "$IMAGES_DIR/$CORE_FILE" | cut -f1))" || \ + RAW_TAR="$IMAGES_DIR/${CORE_FILE%.zst}" + if $CONTAINER_CMD save "$CORE_IMAGE" -o "$RAW_TAR" 2>/dev/null && \ + zstd -q -T0 -15 --rm "$RAW_TAR" -o "$IMAGES_DIR/$CORE_FILE"; then + echo " ✅ Saved core: $CORE_FILE ($(du -h "$IMAGES_DIR/$CORE_FILE" | cut -f1))" + else + rm -f "$RAW_TAR" "$IMAGES_DIR/$CORE_FILE" echo " ⚠️ Failed to save $CORE_IMAGE" + fi else echo " ⚠️ Failed to pull $CORE_IMAGE — baseline app won't work offline" fi @@ -1509,7 +1516,7 @@ done PODMAN="runuser -u archipelago -- env XDG_RUNTIME_DIR=/run/user/$ARCH_UID podman" $PODMAN system migrate >> "$LOG_FILE" 2>&1 || true -for tarfile in "$IMAGES_DIR"/*.tar; do +for tarfile in "$IMAGES_DIR"/*.tar "$IMAGES_DIR"/*.tar.zst; do if [ -f "$tarfile" ]; then echo "$(date): Loading $(basename "$tarfile")..." >> "$LOG_FILE" $PODMAN load -i "$tarfile" >> "$LOG_FILE" 2>&1 && \ @@ -2520,7 +2527,7 @@ fi if [ -d "$BOOT_MEDIA/archipelago/container-images" ]; then echo " Copying container images (this may take a moment)..." mkdir -p /mnt/target/opt/archipelago/container-images - cp -r "$BOOT_MEDIA/archipelago/container-images/"*.tar /mnt/target/opt/archipelago/container-images/ 2>/dev/null || true + cp -r "$BOOT_MEDIA/archipelago/container-images/"*.tar* /mnt/target/opt/archipelago/container-images/ 2>/dev/null || true # Copy first-boot loader script and service mkdir -p /mnt/target/opt/archipelago/scripts