-
Notifications
You must be signed in to change notification settings - Fork 3.3k
[ACR] Add private link and CMK support #12381
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
Changes from all commits
d43c00e
ad57e53
df2edda
3acaa84
319dfb5
814646f
bb9b898
8db6ca1
8a283be
529670a
da33088
875f2e3
63b8969
2299404
f6a2108
fe62ada
07f4c83
5bec13a
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -45,8 +45,12 @@ | |
|
|
||
|
|
||
| def load_arguments(self, _): # pylint: disable=too-many-statements | ||
| SkuName, PasswordName, DefaultAction, PolicyStatus, WebhookAction, WebhookStatus, TaskStatus, BaseImageTriggerType, RunStatus, SourceRegistryLoginMode, UpdateTriggerPayloadType, TokenStatus = self.get_models( | ||
| 'SkuName', 'PasswordName', 'DefaultAction', 'PolicyStatus', 'WebhookAction', 'WebhookStatus', 'TaskStatus', 'BaseImageTriggerType', 'RunStatus', 'SourceRegistryLoginMode', 'UpdateTriggerPayloadType', 'TokenStatus') | ||
| SkuName, PasswordName, DefaultAction, PolicyStatus, WebhookAction, WebhookStatus, TaskStatus, \ | ||
| BaseImageTriggerType, RunStatus, SourceRegistryLoginMode, UpdateTriggerPayloadType, TokenStatus = self.get_models( | ||
| 'SkuName', 'PasswordName', 'DefaultAction', 'PolicyStatus', 'WebhookAction', 'WebhookStatus', | ||
| 'TaskStatus', 'BaseImageTriggerType', 'RunStatus', 'SourceRegistryLoginMode', 'UpdateTriggerPayloadType', | ||
| 'TokenStatus') | ||
|
|
||
| with self.argument_context('acr') as c: | ||
| c.argument('tags', arg_type=tags_type) | ||
| c.argument('registry_name', options_list=['--name', '-n'], help='The name of the container registry. You can configure the default registry name using `az configure --defaults acr=<registry name>`', completer=get_resource_name_completion_list(REGISTRY_RESOURCE_TYPE), configured_default='acr') | ||
|
|
@@ -75,6 +79,10 @@ def load_arguments(self, _): # pylint: disable=too-many-statements | |
| c.argument('default_action', arg_type=get_enum_type(DefaultAction), | ||
| help='Default action to apply when no rule matches. Only applicable to Premium SKU.') | ||
|
|
||
| with self.argument_context('acr create', arg_group="Customer managed key", is_preview=True) as c: | ||
| c.argument('identity', help="Use assigned managed identity resource id or name if in the same resource group") | ||
| c.argument('key_encryption_key', help="key vault key uri") | ||
|
|
||
| with self.argument_context('acr import') as c: | ||
| c.argument('source_image', options_list=['--source'], help="The source identifier will be either a source image name or a fully qualified source.") | ||
| c.argument('source_registry', options_list=['--registry', '-r'], help='The source container registry can be name, login server or resource ID of the source registry.') | ||
|
|
@@ -316,6 +324,21 @@ def load_arguments(self, _): # pylint: disable=too-many-statements | |
| c.argument('password1', options_list=['--password1'], help='Flag indicating if first password should be deleted', action='store_true', required=False) | ||
| c.argument('password2', options_list=['--password2'], help='Flag indicating if second password should be deleted.', action='store_true', required=False) | ||
|
|
||
| with self.argument_context('acr private-endpoint-connection') as c: | ||
| # to match private_endpoint_connection_command_guideline.md guidelines | ||
| c.argument('registry_name', options_list=['--registry-name', '-r'], help='The name of the container registry. You can configure the default registry name using `az configure --defaults acr=<registry name>`', completer=get_resource_name_completion_list(REGISTRY_RESOURCE_TYPE), configured_default='acr') | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I understand that we're on a tight schedule, could we support
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ACR commands right now doesn't support
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Sure. I got it. It's same with storage and keyvault since the name of registry is unique across the whole cloud. But we want to provide consistent UX across services for these four commands. |
||
| c.argument('private_endpoint_connection_name', options_list=['--name', '-n'], help='The name of the private endpoint connection') | ||
|
|
||
| c.argument('approval_description', options_list=['--description'], help='Approval description. For example, the reason for approval.') | ||
| c.argument('rejection_description', options_list=['--description'], help='Rejection description. For example, the reason for rejection.') | ||
|
|
||
| with self.argument_context('acr identity') as c: | ||
| c.argument('identities', nargs='+', help="Space-separated identities. Use '[system]' to refer to the system assigned identity") | ||
|
|
||
| with self.argument_context('acr encryption') as c: | ||
| c.argument('key_encryption_key', help="key vault key uri") | ||
| c.argument('identity', help="client id of managed identity, resource name or id of user assigned identity. Use '[system]' to refer to the system assigned identity") | ||
|
|
||
|
|
||
| def _get_helm_default_install_location(): | ||
| exe_name = 'helm' | ||
|
|
||
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.
Can you add help for
az acr identity assign/remove/showandaz acr encryption show/rotate-key, you can just clone the help from theaz vm.