最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
Virtualbox虚拟机如何导出到Vagrant环境
时间:2022-06-25 02:13:50 编辑:袖梨 来源:一聚教程网
导出虚拟机,选择OVF 0.9格式,导出名称为:exported-file.ova
Export virtualbox appliance with “write legacy OVF 0.9″ option selected. This will create an ova file “exported-file.ova”.
重命名为exported-file.tar
Rename the ova file to “exported-file.tar”
解压exported-file.tar
$ tar -xf exported-file.tar
重命名ovf文件为box.ovf
Copy the content of OVF file to a new file box.ovf.
添加metadata.json文件,内容如下(黑体部分):
Create a new file “metadata.json” with this information:
{
“provider”:”virtualbox”
}
打包这三个文件:
$ tar -cvf exported-file.tar box.ovf vagrant-disk1.vmdk metadata.json
box.ovf
Add the box.ovf and metadata.json to the tar file.
Goto your new box folder, issue vagrant init to create the vagrantfile.
Add the following to the configuration config.vm.box_url = “/DIRECTORY/exported-file.tar”
vagrant up
Guide in Setting Up box for OpenSuse
https://github.com/fnichol/wiki-notes/wiki/Creating-An-openSUSE-11.3-x32-Vagrant-Box
Make sure SSH server runs automatically
/sbin/chkconfig sshd on
相关文章
- GPT-5.6 Sol 如何通过 OpenAI Responses API 创建 AI 应用? 09-18
- GPT-5.6 Sol 的 service_tier 参数如何选择 fast、priority 或 ultrafast? 09-18
- GPT-5.6 Sol 为什么无法在 Chat Completions 中同时使用函数工具和 reasoning_effort? 09-18
- GPT-5.6 Sol 如何用于真实的 Agent 和应用开发任务? 09-18
- 云原生可观测性实战:用 MCP ToolSets 提升 Agent 复杂排障的安全性与协作效率 09-18
- GPT-5.6 Sol 如何用于 AI 编程和自动化应用? 09-18