mirror of
https://github.com/kevingruesser/bootstrap-vz.git
synced 2025-10-11 09:30:30 +00:00
Silly me, putting things where they don't belong
This commit is contained in:
parent
6302d5d962
commit
3cc84c95e8
2 changed files with 5 additions and 5 deletions
|
@ -15,3 +15,8 @@ def validate_manifest(data, validator, error):
|
|||
import os.path
|
||||
schema_path = os.path.normpath(os.path.join(os.path.dirname(__file__), 'manifest-schema.json'))
|
||||
validator(data, schema_path)
|
||||
|
||||
# Check the bootloader/partitioning configuration.
|
||||
# Doing this via the schema is a pain and does not output a useful error message.
|
||||
if data['system']['bootloader'] == 'grub' and data['volume']['partitions']['type'] == 'none':
|
||||
error('Grub cannot boot from unpartitioned disks', ['system', 'bootloader'])
|
||||
|
|
|
@ -71,11 +71,6 @@ class Manifest(object):
|
|||
from . import validate_manifest
|
||||
# Validate the manifest with the base validation function in __init__
|
||||
validate_manifest(self.data, self.schema_validator, self.validation_error)
|
||||
# Check the bootloader/partitioning configuration.
|
||||
# Doing this via the schema is a pain and does not output a useful error message.
|
||||
# This should be put into a separat function if there is more that should be checked like this.
|
||||
if self.data['system']['bootloader'] == 'grub' and self.data['volume']['partitions']['type'] == 'none':
|
||||
self.validation_error('Grub cannot boot from unpartitioned disks', ['system', 'bootloader'])
|
||||
|
||||
# Run the provider validation
|
||||
self.modules['provider'].validate_manifest(self.data, self.schema_validator, self.validation_error)
|
||||
|
|
Loading…
Add table
Reference in a new issue