Change to maximum compression level when using lzma

The deploy image is getting larger and larger, by specifying a higher
compression level, usualy we can save a couple of MB. Smaller image
has higher performance when deploying nodes with PXE.

This patch changes the default compression level to 9 to have the
minimum image size.

Change-Id: Id20292e73796b2c0d72a4d3f5279e02fc3a2757a
This commit is contained in:
Kaifeng Wang 2025-02-03 16:16:02 +08:00
parent 2cab2e4143
commit f340ae3100
2 changed files with 5 additions and 1 deletions

View File

@ -80,7 +80,7 @@ def main():
os.environ['DIB_REPOREF_requirements'] = args.branch
if args.lzma:
os.environ['DIB_IPA_COMPRESS_CMD'] = \
'xz --format=lzma --compress --stdout'
'xz --format=lzma --compress --stdout -9'
# Enable checksum generation by default
if 'DIB_CHECKSUM' not in os.environ:
os.environ['DIB_CHECKSUM'] = 'sha256'

View File

@ -0,0 +1,4 @@
---
features:
- |
Changes lzma compression level to 9 for smaller images.