diff --git a/build_library/virtualbox_ovf.sh b/build_library/virtualbox_ovf.sh index 6a430a7894..06609927f2 100755 --- a/build_library/virtualbox_ovf.sh +++ b/build_library/virtualbox_ovf.sh @@ -51,18 +51,8 @@ datez() { if [[ -n "${FLAGS_output_vagrant}" ]]; then cat >"${FLAGS_output_vagrant}" < "${VM_TMP_DIR}"/metadata.json < "${VM_TMP_DIR}"/box/metadata.json < "${VM_README}" <= 1.2.3 is required. Use something like the following to get started: -vagrant box add coreos path/to/$(basename "${box}") -vagrant init coreos -vagrant up -vagrant ssh - -You will get a warning about "No guest additions were detected...", -this is expected and should be ignored. SSH should work just dandy. -EOF - - # Replace list, not append, since we packaged up the disk image. - VM_GENERATED_FILES=( "${box}" "${VM_README}" ) } _write_vagrant_vmware_fusion_conf() { local vm_mem="${1:-$(_get_vm_opt MEM)}" - local src_name=$(basename "$VM_SRC_IMG") - local dst_name=$(basename "$VM_DST_IMG") - local dst_dir=$(dirname "$VM_DST_IMG") - local vmx_path="${dst_dir}/$(_src_to_dst_name "${src_name}" ".vmx")" - local vmx_file=$(basename "${vmx_path}") - local vfile="${VM_TMP_DIR}/Vagrantfile" - local box="${dst_dir}/$(_src_to_dst_name "${src_name}" ".box")" - - # Move the disk image to tmp, it won't be a final output file - mv "${VM_DST_IMG}" "${VM_TMP_DIR}/${dst_name}" + local vmx=$(_dst_path ".vmx") + mkdir -p "${VM_TMP_DIR}/box" _write_vmx_conf ${vm_mem} - "${BUILD_LIBRARY_DIR}/virtualbox_ovf.sh" \ - --vm_name "$VM_NAME" \ - --disk_vmdk "${VM_TMP_DIR}/${dst_name}" \ - --memory_size "$vm_mem" \ - --output_vagrant "$vfile" + mv "${vmx}" "${VM_TMP_DIR}/box" - cat > "${VM_TMP_DIR}"/metadata.json < "${VM_TMP_DIR}"/box/metadata.json < "${VM_README}" <