variantsdir=$(DESTDIR)$(sysconfdir)/ganeti/instance-debootstrap/variants
defaultsdir=$(DESTDIR)$(sysconfdir)/default
-dist_os_SCRIPTS = create import export rename
-dist_os_DATA = ganeti_api_version variants.list
+dist_os_SCRIPTS = create import export rename verify
+dist_os_DATA = ganeti_api_version variants.list parameters.list
os_DATA = common.sh
dist_doc_DATA = COPYING NEWS README
The Debian version installed by default is now Wheezy.
+The filesystem type for the root partition of instances is now
+configurable through the new OS parameter ``filesystem``. It
+defaults to 'ext4'.
+
Improve documentation with regard to instance variants.
for precise (or just create a symlink called ``precise`` to ``gutsy`` in
``/usr/share/debootstrap/scripts``).
+Instance creation parameters
+----------------------------
+
+Some aspects of the created instance can be conrolled via parameters at
+instance creation time with the ``-O`` parameter of ``gnt-instance``.
+
+The supported parameters are:
+
+- filesystem: the filesystem type to use for the root partition. This has to
+ be a filesystem type supported by ``mke2fs``. The default is 'ext4'.
+
Customization of the instance
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
DEFAULT_PARTITION_STYLE="msdos"
fi
: ${PARTITION_STYLE:=$DEFAULT_PARTITION_STYLE} # disk partition style
+: ${OSP_FILESYSTEM:="ext4"}
CACHE_DIR="@localstatedir@/cache/ganeti-instance-debootstrap"
GETOPT_RESULT=`getopt -o o:n:i:b:s: -n '$0' -- "$@"`
if [ $? != 0 ] ; then log_error "Terminating..."; exit 1 ; fi
get_api5_arguments $GETOPT_RESULT
-elif [ "$OS_API_VERSION" = "10" -o "$OS_API_VERSION" = "15" ]; then
+elif [ "$OS_API_VERSION" = "10" -o "$OS_API_VERSION" = "15" -o \
+ "$OS_API_VERSION" = "20" ]; then
get_api10_arguments
else
log_error "Unknown OS API VERSION $OS_API_VERSION"
exit 1
fi
-mke2fs -Fjq $filesystem_dev
+mke2fs -Fjqt $OSP_FILESYSTEM $filesystem_dev
root_uuid=$($VOL_ID $filesystem_dev )
if [ -n "$swapdev" ]; then
--- /dev/null
+filesystem The filesystem type to use for the root partition. This has to be a filesystem type supported by ``mke2fs``. The default is 'ext4'.
--- /dev/null
+#!/bin/bash
+
+# Copyright (C) 2007, 2008, 2009 Google Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+# 02110-1301, USA.
+
+set -e
+
+case $OSP_FILESYSTEM in
+ ""|"ext2"|"ext3"|"ext4")
+ ;;
+ *)
+ echo "Invalid value '$OSP_FILESYSTEM' for the filesystem parameter" 1>&2
+ exit 1
+ ;;
+esac
+
+exit 0
+