Merge "Use megabyte granularity for image extra space"
This commit is contained in:
commit
3d3ba26edd
@ -381,8 +381,8 @@ else
|
|||||||
sudo du -a -c -x ${TMP_BUILD_DIR}/built > ${du_output}
|
sudo du -a -c -x ${TMP_BUILD_DIR}/built > ${du_output}
|
||||||
# the last line is the total size from "-c".
|
# the last line is the total size from "-c".
|
||||||
if [ -n "$DIB_IMAGE_EXTRA_SIZE" ]; then
|
if [ -n "$DIB_IMAGE_EXTRA_SIZE" ]; then
|
||||||
# add DIB_IMAGE_EXTRA_SIZE to create a bigger image as requested
|
# add DIB_IMAGE_EXTRA_SIZE megabytes to create a bigger image as requested
|
||||||
du_extra_size=$(echo "$DIB_IMAGE_EXTRA_SIZE" | awk '{printf("%d\n",$1 * 1024 *1024)}')
|
du_extra_size=$(echo "$DIB_IMAGE_EXTRA_SIZE" | awk '{printf("%d\n",$1 * 1024)}')
|
||||||
du_size_tmp=$(tail -n1 ${du_output} | cut -f1)
|
du_size_tmp=$(tail -n1 ${du_output} | cut -f1)
|
||||||
du_size=$(echo "$du_size_tmp $du_extra_size" | awk '{print int($1 + $2)}')
|
du_size=$(echo "$du_size_tmp $du_extra_size" | awk '{print int($1 + $2)}')
|
||||||
else
|
else
|
||||||
|
@ -627,7 +627,7 @@ following arguments:
|
|||||||
|
|
||||||
``--image-extra-size``
|
``--image-extra-size``
|
||||||
Extra space to add when automatically calculating image size, in
|
Extra space to add when automatically calculating image size, in
|
||||||
gigabytes. This overrides the default 60% scale up as described
|
megabytes. This overrides the default 60% scale up as described
|
||||||
above for ``--image-size``. Can also set ``DIB_IMAGE_EXTRA_SIZE``.
|
above for ``--image-size``. Can also set ``DIB_IMAGE_EXTRA_SIZE``.
|
||||||
|
|
||||||
The special node named ``mkfs_root`` is affected by the following;
|
The special node named ``mkfs_root`` is affected by the following;
|
||||||
|
@ -0,0 +1,5 @@
|
|||||||
|
---
|
||||||
|
upgrade:
|
||||||
|
- |
|
||||||
|
The ``--image-extra-size`` argument has changed from gigabytes to
|
||||||
|
megabytes to make it more practical for use on smaller images.
|
Loading…
Reference in New Issue
Block a user