Add helpful message to volsize%1024 error

This commit is contained in:
Anders Ingemann 2013-10-27 10:02:11 +01:00
parent 1b5a1e0579
commit c95b9077e5

View file

@ -11,7 +11,8 @@ class Manifest(base.Manifest):
if data['volume']['backing'] == 'ebs':
volume_size = self._calculate_volume_size(data['volume']['partitions'])
if volume_size % 1024 != 0:
msg = 'The volume size must be a multiple of 1024 when using EBS backing'
msg = ('The volume size must be a multiple of 1024 when using EBS backing '
'(MBR partitioned volumes are 1MB larger than specified, for the post-mbr gap)')
raise ManifestError(msg, self)
else:
schema_path = path.join(path.dirname(__file__), 'manifest-schema-s3.json')