This is an automated email from the ASF dual-hosted git repository.

lfrolov pushed a commit to branch DATALAB-2333
in repository https://gitbox.apache.org/repos/asf/incubator-datalab.git


The following commit(s) were added to refs/heads/DATALAB-2333 by this push:
     new 5f76418  [DATALAB-2333]: added iteration of policies list
5f76418 is described below

commit 5f76418245f3a4248958518783a280ab2d960153
Author: leonidfrolov <[email protected]>
AuthorDate: Mon May 24 16:02:58 2021 +0300

    [DATALAB-2333]: added iteration of policies list
---
 infrastructure-provisioning/src/general/lib/aws/actions_lib.py | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/infrastructure-provisioning/src/general/lib/aws/actions_lib.py 
b/infrastructure-provisioning/src/general/lib/aws/actions_lib.py
index f35f94b..1e3a526 100644
--- a/infrastructure-provisioning/src/general/lib/aws/actions_lib.py
+++ b/infrastructure-provisioning/src/general/lib/aws/actions_lib.py
@@ -956,8 +956,9 @@ def remove_all_iam_resources(instance_type, 
project_name='', endpoint_name=''):
                         print('There is no policy {}-ssn-policy to 
delete'.format(service_base_name))
                     attached_role_policies = 
client.list_attached_role_policies(RoleName=iam_role)
                     if attached_role_policies:
-                        print('========1')
-                        print(attached_role_policies)
+                        for policy in attached_role_policies:
+                            print('========1')
+                            print(policy)
                     role_profiles = 
client.list_instance_profiles_for_role(RoleName=iam_role).get('InstanceProfiles')
                     if role_profiles:
                         for i in role_profiles:

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to