我看到了使用vhd文件创建图像并使用该映像文件创建vm的示例。我使用手臂模式,并希望将我上传的vhd列为图像。基本上我想要使用azure cli/java sdk在以下文章https://azure.microsoft.com/en-in/documentation/articles/virtual-machines-windows-classic-createupload-vhd/中执行第5步。我没有看到这样做的任何例子。 有一个cli命令'azure vm image create',但它是否已在azure-cli 0.10.1版中弃用?我已经为mac安装了预编译的azure-cli版本。使用天蓝色的cli创建自定义vhd的图像
0
A
回答
0
据我所知,没有证据表明在azure-cli 0.10.1版本中不支持命令azure vm image create
。您现在可以通过命令npm update -g azure-cli
将azure-cli版本升级到0.10.2。
对于做article的步骤5中,你可以尝试参考文章使用的命令azure vm image create
与ASM
模式“天青CLI在Azure的服务管理(ASM)模式命令”的部分Commands to manage your Azure virtual machine images
,请参阅下面的步骤。
# Sets the cli wording mode with asm
$ azure config mode asm
# See the help manual for the command `vm image create`
$ azure vm image creaet -h
help: Upload and register a VM image
help:
help: Usage: vm image create [options] <name> [source-path]
help:
help: Options:
help: -h, --help output usage information
help: -v, --verbose use verbose output
help: -vv more verbose with debug output
help: --json use json output
help: -u, --blob-url <url> the target image blob url
help: -l, --location <name> the location
help: -a, --affinity-group <name> the affinity group
help: -o, --os <type> the operating system [linux|windows]
help: -p, --parallel <number> the maximum number of parallel uploads [96]
help: -m, --md5-skip skip MD5 hash computation
help: -f, --force-overwrite Force overwrite of prior uploads
help: -e, --label <about> the image label
help: -d, --description <about> the image description
help: -b, --base-vhd <blob> the base vhd blob url
help: -k, --source-key <key> the source storage key if source-path
help: is a Microsoft Azure private blob url
help: -s, --subscription <id> the subscription id
help:
help: Current Mode: asm (Azure Service Management)
# Does the step 5 like Azure-AddVMImage
$ azure vm image create <ImageName> -b <vhd-blob-url> -o <ostype: linux|windows>
同时,我认为从创建自定义图像虚拟机的简单方法是使用Azure的CLI与ARM从模板,你可以参考article与the template sample GitHub上。
相关问题
- 1. 在Microsoft Azure中使用CLI中的映像(.VHD)创建Windows VM
- 2. 如何从快照创建天蓝色的图像?
- 3. 蔚蓝的.vhd图像捕获/负载
- 4. 为天蓝色容器创建天蓝色cdn端点
- 5. 无法在ARM中创建天蓝色图像
- 6. 如何在天蓝色的云中创建天蓝色的堆栈
- 7. 使用自定义构建脚本将mvc 3网站部署到天蓝色
- 8. UIDocumentMenuViewController的自定义图像只显示蓝色框
- 9. 如何创建像自定义列表视图的自定义图像视图?
- 10. 创建天蓝色节流异常
- 11. 创建天蓝色广告组
- 12. 服务管理员如何获得足够的权限来创建天蓝色的自定义角色
- 13. TKCalendar - 一天的自定义图像?
- 14. 为医学成像创建红蓝绿色的色彩图吗?
- 15. 无法将VHD上传到天蓝色故障
- 16. 上传图像(blob)到天蓝色的特定容器
- 17. 自动天蓝色部署
- 18. 自定义PDF创建 - 大图像
- 19. 创建具有自定义图像帧
- 20. 使用Png(透明)图像和背景颜色创建自定义画笔
- 21. 创建自定义头像
- 22. 如何创建蓝色文件存储SAS网址(没有天蓝色的库)?
- 23. 将aurelia自定义元素创建为npm包(使用Aurelia CLI)
- 24. Azure存储自定义域名仍保留天蓝色域?
- 25. azure无法从vhd图像创建vm图像
- 26. 使用Image Magick创建带固定颜色图的GIF图像
- 27. 可能保持两个vhd的同步在天蓝色虚拟的
- 28. 如何使用Crystal Reports中图表的颜色创建自定义图例表?
- 29. 使用UIImage和其他属性创建自定义图像
- 30. 在flex中创建自定义组件时使用图像
谢谢彼得。我在ARM模式下工作,我已经将我的vhd blob上传到其中一个资源组。现在我只需要从这个vhd文件中创建一个图像。在预览门户网站上似乎也无法做到这一点。那么,没有使用模板的话,没有办法做到这一点吗? –
由于ARM是建议在任何地方使用的,我想找到一种使用资源组创建自定义图像的方法。几乎没有任何关于在非Windows平台上创建用户图像的文档。 –