From 1784ecd51552985789340db22f74ea20e0421123 Mon Sep 17 00:00:00 2001 From: Corey Hemminger Date: Mon, 18 Mar 2024 18:14:31 -0500 Subject: [PATCH] testing --- .gitignore | 1 + amazon_linux_2_virtualbox_build.sh | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 175b1f75c..14efcc395 100644 --- a/.gitignore +++ b/.gitignore @@ -5,6 +5,7 @@ *.ovf *.vmdk *.vdi +*.qcow2 *.log virtualfloppy.vfd packer_cache/ diff --git a/amazon_linux_2_virtualbox_build.sh b/amazon_linux_2_virtualbox_build.sh index e5cff7428..a57c99ffd 100755 --- a/amazon_linux_2_virtualbox_build.sh +++ b/amazon_linux_2_virtualbox_build.sh @@ -36,7 +36,7 @@ echo "Creating the VM" # from https://www.perkin.org.uk/posts/create-virtualbox-vm-from-the-command-line.html VBoxManage createvm --name $VM --ostype "RedHat_64" --register VBoxManage storagectl $VM --name "SATA Controller" --add sata --controller IntelAHCI -VBoxManage storageattach $VM --storagectl "SATA Controller" --port 0 --device 0 --type hdd --medium "$AMZDIR"/amazon.vdi +VBoxManage storageattach $VM --storagectl "SATA Controller" --port 0 --device 0 --type hdd --medium "$AMZDIR"/amazon2.vdi VBoxManage storageattach $VM --storagectl "SATA Controller" --port 0 --device 1 --type dvddrive --medium "$AMZDIR"/seed.iso VBoxManage modifyvm $VM --memory 2048 VBoxManage modifyvm $VM --cpus 2 @@ -59,7 +59,7 @@ echo Deleting the VM vboxmanage unregistervm $VM --delete echo starting packer build of amazonlinux -if packer build -timestamp-ui -only=virtualbox-ovf.amazonlinux -var-file="$AMZDIR"/../../os_pkrvars/amazonlinux/amazonlinux-2-x86_64.pkrvars.hcl "$AMZDIR"/../../packer_templates; then +if packer build -timestamp-ui -only=virtualbox-ovf.vm -var "vbox_source_path=$AMZDIR/amazon2.vdi" -var "vbox_checksum=null" -var-file="$AMZDIR"/../../os_pkrvars/amazonlinux/amazonlinux-2-x86_64-virtualbox.pkrvars.hcl "$AMZDIR"/../../packer_templates; then echo "Cleaning up files" rm -f "$AMZDIR"/*.ovf "$AMZDIR"/*.vmdk "$AMZDIR"/*.iso else