{"id":191,"date":"2015-05-18T12:50:00","date_gmt":"2015-05-18T12:50:00","guid":{"rendered":"https:\/\/blogs.msdn.microsoft.com\/azuregov\/2015\/05\/18\/adding-vm-depot-images-to-azure-government\/"},"modified":"2015-05-18T12:50:00","modified_gmt":"2015-05-18T12:50:00","slug":"adding-vm-depot-images-to-azure-government","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/azuregov\/adding-vm-depot-images-to-azure-government\/","title":{"rendered":"Adding VM Depot Images to Azure Government"},"content":{"rendered":"<p>&nbsp;<\/p>\n<p>Azure provides many mechanisms to get the virtual machine of choice loaded into your subscription.&nbsp;The Azure Government gallery includes numerous images from Barracuda, Bitnami, CloudLink, Microsoft, Oracle, and SUSE.&nbsp; The full list is <a href=\"http:\/\/azure.microsoft.com\/en-us\/documentation\/articles\/azure-government-image-gallery\/\">here<\/a>.&nbsp; It is also pretty straightforward to upload your own, or copy one from an existing subscription in public Azure.&nbsp; VM Depot is directly integrated into the Azure portal to make it easy to deploy one of the 1000&rsquo;s of images developed by the open source community.&nbsp; In this post, we will show you how to leverage one of the&nbsp;many images located in <a href=\"https:\/\/vmdepot.msopentech.com\/List\/Index\">VM Depot<\/a> and easily move it into your Azure Government subscription.&nbsp;<\/p>\n<p>If you are unfamiliar with VM Depot, it is a community managed repository of Linux and FreeBSD virtual images that integrates directly with Microsoft Azure.&nbsp; The community is sponsored by Microsoft Open Technologies group which is focused on advancing Open Standards and Technologies on Microsoft&rsquo;s platform.<\/p>\n<p>To start off, you will need both and Azure subscription, and an Azure Government subscription.<\/p>\n<h2>Choose and deploy your image to Azure<\/h2>\n<p>When you log into your Azure subscription, at manage.windowsazure.com you navigate to Virtual Machines &#8211;&gt;&nbsp; Images.&nbsp;The images tab includes a &ldquo;Browse VM Depot&rdquo; option to select your VM of choice:<\/p>\n<p> <a href=\"https:\/\/devblogs.microsoft.com\/wp-content\/uploads\/sites\/43\/2019\/03\/0830.blogPic1.png\"><img decoding=\"async\" src=\"https:\/\/devblogs.microsoft.com\/wp-content\/uploads\/sites\/43\/2019\/03\/0830.blogPic1.png\" alt=\"\" width=\"340\" height=\"85\" border=\"0\" \/><\/a><br \/>&nbsp;<br \/>The popup includes a full list of images available, you can either peruse here or directly at VM Depot.&nbsp; I have decided to deploy a version of Apache running on CentOS, published by Cognosys.<\/p>\n<p><a href=\"https:\/\/devblogs.microsoft.com\/wp-content\/uploads\/sites\/43\/2019\/03\/8203.blogpic2.png\"><img decoding=\"async\" src=\"https:\/\/devblogs.microsoft.com\/wp-content\/uploads\/sites\/43\/2019\/03\/8203.blogpic2.png\" alt=\"\" border=\"0\" \/><\/a><\/p>\n<p>After it has completed the copy, your image is in the &ldquo;Pending Registration&rdquo; status.&nbsp; You must register the VM as an image to show up in your Image Gallery.&nbsp; To do this, simply select the disk image, and select&nbsp;<br \/>&nbsp;<a href=\"https:\/\/devblogs.microsoft.com\/wp-content\/uploads\/sites\/43\/2019\/03\/3580.Blog%20Pic%204.png\"><img decoding=\"async\" src=\"https:\/\/devblogs.microsoft.com\/wp-content\/uploads\/sites\/43\/2019\/03\/3580.Blog%20Pic%204.png\" alt=\"\" width=\"69\" height=\"65\" border=\"0\" \/><\/a>&nbsp;in the actions bar.<\/p>\n<p>&nbsp;<\/p>\n<p>If you go to &#8220;My Images&#8221; to&nbsp;deploy an image through the Image Gallery it will now show up similar to the below:<\/p>\n<p>&nbsp;<a href=\"https:\/\/devblogs.microsoft.com\/wp-content\/uploads\/sites\/43\/2019\/03\/8032.Blog%20Pic%205.png\"><img decoding=\"async\" src=\"https:\/\/devblogs.microsoft.com\/wp-content\/uploads\/sites\/43\/2019\/03\/8032.Blog%20Pic%205.png\" alt=\"\" border=\"0\" \/><\/a><\/p>\n<p>&nbsp;<\/p>\n<p>Now for the fun part.&nbsp; We have deployed and gotten this image ready in Public Azure, but how do we get it into Azure Government?&nbsp; Well, the steps are quite easy.&nbsp; First you must copy the VHD to Azure Government, and then you have to register the Virtual Hard Drive (VHD) as a valid image. &nbsp;<\/p>\n<h2>Copying the image to Azure Government<\/h2>\n<p><a href=\"http:\/\/azure.microsoft.com\/en-us\/documentation\/articles\/storage-use-azcopy\/\">AzCopy<\/a>&nbsp;is an excellent tool for copying disk images between Azure Regions and\\or Azure Government.&nbsp; I consistently get very high bandwidth rates when going between Azure DCs and highly recommend it.&nbsp; To move between 2 storage containers you will need the Source and Destination Access Key, which you can obtain from Storage Container<\/p>\n<p style=\"padding-left: 30px\">Azcopy \/source:https:\/\/&lt;YourContainer&gt;.blob.core.windows.net\/communityimages\/ \/dest:https:\/\/&lt;your destination&gt;.blob.core.usgovcloudapi.net\/vhds\/&nbsp; \/pattern:community-520-f2222140-29c5-410a-b8da-0c1d93023a4c-1.vhd \/sourcekey:&lt;SourceKey&gt; \/destkey:&lt;DestKey&gt;<\/p>\n<p>&nbsp;<\/p>\n<p>Now you have to add the VHD as an image to your subscriptions Image Gallery with the following command,&nbsp; for all the metadata I copied from the publishers content in VM Depot.<\/p>\n<p>&nbsp;<\/p>\n<p style=\"padding-left: 30px\">Add-AzureVMImage -ImageName &#8220;Apache-2-2-15-on-OpenLogic-CentOS-6-3&#8221;&nbsp;&nbsp;&nbsp; -MediaLocation<br \/>&#8220;https:\/\/&lt;Your Container&gt;.blob.core.usgovcloudapi.net\/vhds\/community-520-f2222140-29c5-410a-b8da-0c1d93023a4c-1.vhd&#8221;<br \/>-OS &#8220;Linux&#8221;&nbsp;&nbsp; -Label &#8220;Apache 2.2.15 on OpenLogic CentOS 6.3&#8221; -Eula <a href=\"https:\/\/vmdepot.msopentech.com\/User\/DefaultToU\">https:\/\/vmdepot.msopentech.com\/User\/DefaultToU<\/a>`&nbsp;-Description<br \/>&#8220;Cognosys brings you Apache\/2.2.15 on OpenLogic CentOS 6.3. Port 80 should be open in load balancer to access the<br \/>server&#8221; -ImageFamily &#8220;Linux&#8221; -PublishedDate &#8220;2\/26\/2013&#8221;&nbsp; `&nbsp;-PrivacyUri &#8216;https:\/\/vmdepot.msopentech.com\/User\/DefaultToU&#8217;<br \/>-RecommendedVMSize &#8220;Medium&#8221;<\/p>\n<p>&nbsp;<\/p>\n<p>After successfully deploying, you should now see the same apache image in your Image Gallery as shown below.<\/p>\n<p>&nbsp;<a href=\"https:\/\/msdnshared.blob.core.windows.net\/media\/MSDNBlogsFS\/prod.evol.blogs.msdn.com\/CommunityServer.Blogs.Components.WeblogFiles\/00\/00\/01\/69\/85\/2766.BlogPic6.PNG\"><img decoding=\"async\" src=\"https:\/\/msdnshared.blob.core.windows.net\/media\/MSDNBlogsFS\/prod.evol.blogs.msdn.com\/CommunityServer.Blogs.Components.WeblogFiles\/00\/00\/01\/69\/85\/2766.BlogPic6.PNG\" alt=\"\" border=\"0\" \/><\/a><\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>&nbsp; Azure provides many mechanisms to get the virtual machine of choice loaded into your subscription.&nbsp;The Azure Government gallery includes numerous images from Barracuda, Bitnami, CloudLink, Microsoft, Oracle, and SUSE.&nbsp; The full list is here.&nbsp; It is also pretty straightforward to upload your own, or copy one from an existing subscription in public Azure.&nbsp; VM [&hellip;]<\/p>\n","protected":false},"author":1755,"featured_media":20423,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[1],"tags":[],"class_list":["post-191","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-azuregov"],"acf":[],"blog_post_summary":"<p>&nbsp; Azure provides many mechanisms to get the virtual machine of choice loaded into your subscription.&nbsp;The Azure Government gallery includes numerous images from Barracuda, Bitnami, CloudLink, Microsoft, Oracle, and SUSE.&nbsp; The full list is here.&nbsp; It is also pretty straightforward to upload your own, or copy one from an existing subscription in public Azure.&nbsp; VM [&hellip;]<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/azuregov\/wp-json\/wp\/v2\/posts\/191","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/azuregov\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/azuregov\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/azuregov\/wp-json\/wp\/v2\/users\/1755"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/azuregov\/wp-json\/wp\/v2\/comments?post=191"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/azuregov\/wp-json\/wp\/v2\/posts\/191\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/azuregov\/wp-json\/wp\/v2\/media\/20423"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/azuregov\/wp-json\/wp\/v2\/media?parent=191"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/azuregov\/wp-json\/wp\/v2\/categories?post=191"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/azuregov\/wp-json\/wp\/v2\/tags?post=191"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}