Skip to content
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

[Profile] Deprecate --sdk-auth #19414

Merged
merged 3 commits into from
Oct 8, 2021
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,9 @@ def load_arguments(self, command):
c.ignore('_subscription') # hide the global subscription parameter

with self.argument_context('account show') as c:
c.argument('show_auth_for_sdk', options_list=['--sdk-auth'], action='store_true', help='Output result to a file compatible with Azure SDK auth. Only applicable when authenticating with a Service Principal.')
c.argument('show_auth_for_sdk', options_list=['--sdk-auth'], action='store_true',
deprecate_info=c.deprecate(target='--sdk-auth', expiration='3.0.0'),
help='Output result to a file compatible with Azure SDK auth. Only applicable when authenticating with a Service Principal.')

with self.argument_context('account get-access-token') as c:
c.argument('resource_type', get_enum_type(cloud_resource_types), options_list=['--resource-type'], arg_group='', help='Type of well-known resource.')
Expand Down
4 changes: 3 additions & 1 deletion src/azure-cli/azure/cli/command_modules/role/_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,9 @@ def load_arguments(self, _):
help='Skip creating the default assignment, which allows the service principal to access resources under the current subscription. '
'When specified, --scopes will be ignored. You may use `az role assignment create` to create '
'role assignments for this service principal later.')
c.argument('show_auth_for_sdk', options_list='--sdk-auth', help='output result in compatible with Azure SDK auth file', arg_type=get_three_state_flag())
c.argument('show_auth_for_sdk', options_list='--sdk-auth',
deprecate_info=c.deprecate(target='--sdk-auth', expiration='3.0.0'),
help='output result in compatible with Azure SDK auth file', arg_type=get_three_state_flag())

with self.argument_context('ad sp owner list') as c:
c.argument('identifier', options_list=['--id'], help='service principal name, or object id or the service principal')
Expand Down