From d2867c47f0f6b044775dd260b47f3b15df6bead1 Mon Sep 17 00:00:00 2001 From: Megan Marsh Date: Thu, 31 Oct 2019 14:43:46 -0700 Subject: [PATCH] allow nvme, since virtualbox 6.0 allows it --- builder/virtualbox/iso/builder.go | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/builder/virtualbox/iso/builder.go b/builder/virtualbox/iso/builder.go index 5ff62c54e..11d5784c5 100644 --- a/builder/virtualbox/iso/builder.go +++ b/builder/virtualbox/iso/builder.go @@ -193,9 +193,12 @@ func (b *Builder) Prepare(raws ...interface{}) ([]string, error) { "packer-%s-%d", b.config.PackerBuildName, interpolate.InitTime.Unix()) } - if b.config.HardDriveInterface != "ide" && b.config.HardDriveInterface != "sata" && b.config.HardDriveInterface != "scsi" { + switch b.config.HardDriveInterface { + case "ide", "sata", "scsi", "nvme": + // do nothing + default: errs = packer.MultiErrorAppend( - errs, errors.New("hard_drive_interface can only be ide, sata, or scsi")) + errs, errors.New("hard_drive_interface can only be ide, sata, nvme or scsi")) } if b.config.SATAPortCount == 0 {