-
Notifications
You must be signed in to change notification settings - Fork 159
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
gallery image reference and security profile support for VMs #1162
base: master
Are you sure you want to change the base?
Conversation
@@ -821,6 +821,19 @@ module Vm = | |||
OS: OS | |||
} | |||
|
|||
type GalleryImageId = |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would it be possible to use the GalleryImageIdentifier
from gallery image builder instead of an arbitrary string?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Despite both using the term "gallery" the distributing mechanism seems to be different depending on reference method used - the offer/sku refers to the "marketplace", while the string id references azure gallery artifact, the listings are completely independent and while the same image may appear in both there's no direct correspondence between any part of id string of the gallery and offer/sku of the marketplace.
Using the string reference in the deployment also involves completely different validation flow.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see now - this is not the gallery image identifier, this is the ARM resource identifier for the image from the gallery. It just should be ResourceId
, same as in the ImageTemplate.SharedImageVersionSource.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You'd think so, but shared and community galleries references do not refer to ARM resources and have no type, subscription or resource group, for example: /sharedGalleries/CblMariner.1P/images/cbl-mariner-2-gen2/versions/latest
and make it possible to access images shared tenant-wide or cloud-wide, respectively, w/o having access to the subscription where the gallery resides.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated reference type to enforce a bit of structure in the URIs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For comparison, the imageTemplate format is /subscriptions/111111111-1111-1111-1111-111111111111/resourcegroups/mydtlrg/providers/microsoft.devtestlab/labs/mydtllab/sharedgalleries/spsig/sharedimages/myimagefromgallery
This PR closes #1161 and closes #1163
The changes in this PR are as follows:
ImageInfo
DU to support gallery image references as well as existing image SKUsOS
when configuring a VM - purely to maintain farmer validationI have read the contributing guidelines and have completed the following:
Below is a minimal example configuration that includes the new features, which can be used to deploy to Azure: