Add configurable template root volume size
Allow to override default 10G.
This commit is contained in:
parent
4d73c0abc7
commit
310837b4ee
5
Makefile
5
Makefile
@ -17,8 +17,9 @@ TEMPLATE_ENV_WHITELIST += \
|
||||
DIST DISTRIBUTION TEMPLATE_SCRIPTS TEMPLATE_NAME TEMPLATE_FLAVOR \
|
||||
TEMPLATE_FLAVOR_DIR TEMPLATE_OPTIONS APPMENUS_DIR \
|
||||
VERBOSE DEBUG PATH BUILDER_DIR SRC_DIR DISCARD_PREPARED_IMAGE \
|
||||
TEMPLATE_ROOT_WITH_PARTITIONS USE_QUBES_REPO_VERSION \
|
||||
USE_QUBES_REPO_TESTING BUILDER_TURBO_MODE REPO_PROXY FEDORA_MIRROR \
|
||||
TEMPLATE_ROOT_WITH_PARTITIONS TEMPLATE_ROOT_SIZE \
|
||||
USE_QUBES_REPO_VERSION USE_QUBES_REPO_TESTING \
|
||||
BUILDER_TURBO_MODE REPO_PROXY FEDORA_MIRROR \
|
||||
CENTOS_MIRROR EPEL_MIRROR
|
||||
|
||||
# Make sure names are < 32 characters, process aliases
|
||||
|
@ -28,6 +28,10 @@ if [ "${VERBOSE}" == "1" ]; then
|
||||
export YUM_OPTS="${YUM_OPTS} -q"
|
||||
fi
|
||||
|
||||
if [ -z "$TEMPLATE_ROOT_SIZE" ]; then
|
||||
TEMPLATE_ROOT_SIZE=10G
|
||||
fi
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# Make sure INSTALLDIR exists
|
||||
# ------------------------------------------------------------------------------
|
||||
@ -54,7 +58,7 @@ if [ -f "${IMG}" ]; then
|
||||
fi
|
||||
else
|
||||
echo "-> Initializing empty image..."
|
||||
truncate -s 10G "${IMG}" || exit 1
|
||||
truncate -s "$TEMPLATE_ROOT_SIZE" "${IMG}" || exit 1
|
||||
|
||||
if [ "0$TEMPLATE_ROOT_WITH_PARTITIONS" -eq 1 ]; then
|
||||
echo "-> Creating partition table"
|
||||
|
Loading…
Reference in New Issue
Block a user