mirror of
https://github.com/kevingruesser/bootstrap-vz.git
synced 2025-08-24 15:36:27 +00:00
Extlinux now works on virtualbox
Raise error when trying to install grub on unpartitioned disks
This commit is contained in:
parent
35d6140cb1
commit
f16939eef5
3 changed files with 7 additions and 3 deletions
|
@ -126,5 +126,6 @@ class InstallExtLinux(Task):
|
||||||
def run(cls, info):
|
def run(cls, info):
|
||||||
from common.tools import log_check_call
|
from common.tools import log_check_call
|
||||||
log_check_call(['/usr/sbin/chroot', info.root,
|
log_check_call(['/usr/sbin/chroot', info.root,
|
||||||
'/usr/bin/extlinux',
|
'/usr/sbin/extlinux-install', info.volume.device_path])
|
||||||
'--install', '/boot'])
|
log_check_call(['/usr/sbin/chroot', info.root,
|
||||||
|
'/usr/sbin/extlinux-update'])
|
||||||
|
|
|
@ -20,6 +20,9 @@ def validate_manifest(data, validator, error):
|
||||||
schema_path = os.path.normpath(os.path.join(os.path.dirname(__file__), 'manifest-schema.json'))
|
schema_path = os.path.normpath(os.path.join(os.path.dirname(__file__), 'manifest-schema.json'))
|
||||||
validator(data, schema_path)
|
validator(data, schema_path)
|
||||||
|
|
||||||
|
if data['volume']['partitions']['type'] == 'none' and data['system']['bootloader'] != 'extlinux':
|
||||||
|
error('Only extlinux can boot from unpartitioned disks', ['system', 'bootloader'])
|
||||||
|
|
||||||
|
|
||||||
def resolve_tasks(tasklist, manifest):
|
def resolve_tasks(tasklist, manifest):
|
||||||
import common.task_sets
|
import common.task_sets
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
"properties": {
|
"properties": {
|
||||||
"bootloader": {
|
"bootloader": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"enum": ["grub"]
|
"enum": ["grub", "extlinux"]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
Loading…
Add table
Reference in a new issue