allow switching between vmdk images with IDE or SCSI controller
This commit is contained in:
parent
9a6000e89c
commit
abc5c6d49b
10
Makefile
10
Makefile
|
@ -9,6 +9,7 @@ IMAGES = $(VABUILDER_OUTPUT)/images
|
|||
RAW_IMAGE = $(IMAGES)/$(APPLIANCE).img
|
||||
QCOW_IMAGE = $(IMAGES)/$(APPLIANCE).qcow
|
||||
VMDK_IMAGE = $(IMAGES)/$(APPLIANCE).vmdk
|
||||
VMDK_TYPE = IDE
|
||||
XVA_IMAGE = $(IMAGES)/$(APPLIANCE).xva
|
||||
LST_FILE = $(IMAGES)/$(APPLIANCE)-packages.lst
|
||||
CHECKSUMS = $(IMAGES)/SHA256SUMS
|
||||
|
@ -302,7 +303,11 @@ xva: $(XVA_IMAGE)
|
|||
|
||||
$(VMDK_IMAGE): $(RAW_IMAGE)
|
||||
@print Creating `basename $(VMDK_IMAGE)`
|
||||
ifeq ($(VMDK_TYPE),SCSI)
|
||||
qemu-img convert -f raw -O vmdk -o adapter_type=lsilogic,subformat=streamOptimized,compat6 $(RAW_IMAGE) $(VMDK_IMAGE).tmp
|
||||
else
|
||||
qemu-img convert -f raw -O vmdk $(RAW_IMAGE) $(VMDK_IMAGE).tmp
|
||||
endif
|
||||
mv $(VMDK_IMAGE).tmp $(VMDK_IMAGE)
|
||||
|
||||
vmdk: $(VMDK_IMAGE)
|
||||
|
@ -390,8 +395,9 @@ help:
|
|||
@echo 'EXTERNAL_KERNEL=YES - Do not build a kernel in the image'
|
||||
@echo 'HEADLESS=YES - Build a headless (serial console) image.'
|
||||
@echo 'ENABLE_SSHD=YES - Enable sshd to start automatically in the image'
|
||||
@echo 'VMDK_TYPE=IDE - VMDK image type (IDE or SCSI)'
|
||||
@echo
|
||||
@print 'Example'
|
||||
@echo 'make APPLIANCE=mongodb HEADLESS=YES VIRTIO=YES stage4 qcow clean'
|
||||
@print 'Example to build the base appliance'
|
||||
@echo 'make APPLIANCE=base HEADLESS=YES VIRTIO=YES stage4 qcow clean'
|
||||
|
||||
.PHONY: qcow vmdk clean realclean distclean stage4 image stage4 help appliance-list eclean sync_portage sync_stage3 checksums
|
||||
|
|
Loading…
Reference in New Issue