Skip to content

Commit 1a1b3fd

Browse files
authored
Fix Azure role assignments and app removal (#128)
* Add role assignment for Azure Ranger Audit role * Delete Azure AD app during teardown Signed-off-by: Jim Enright <jenright@cloudera.com>
1 parent 11793ab commit 1a1b3fd

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

roles/platform/tasks/setup_azure_authz.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -201,6 +201,11 @@
201201
scope: "{{ plat__azure_datapath_uri }}"
202202
assignee: "{{ __azure_ranger_audit_identity.properties.principalId }}"
203203
desc: Assign Storage Blob Data Contributor Role to Ranger Audit Role at Data Container level
204+
- role: "{{ __azure_storageblobdata_ctrb_role_id }}"
205+
scope: "{{ plat__azure_logpath_uri }}"
206+
assignee: "{{ __azure_ranger_audit_identity.properties.principalId }}"
207+
desc: Assign Storage Blob Data Contributor Role to Ranger Audit Role at Logs Container level
208+
204209
loop_control:
205210
loop_var: __azure_rl_assgn_item
206211
label: "{{ __azure_rl_assgn_item.desc }}"

roles/platform/tasks/teardown_azure_authz.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,8 @@
7474
- name: Tear down Azure AD App Registration
7575
when: plat__teardown_deletes_xaccount and ( plat__azure_xaccount_app_uuid is defined ) and ( plat__azure_xaccount_app_uuid | length > 0 )
7676
command: >
77-
az ad sp delete
78-
--id {{ plat__azure_application_service_principal_objuuid }}
77+
az ad app delete
78+
--id {{ plat__azure_xaccount_app_uuid }}
7979
8080
- name: Tear down Custom Role
8181
when: plat__teardown_deletes_roles

0 commit comments

Comments
 (0)