fixed some names for IAM code
parent
b398a21cc8
commit
43f300de99
|
@ -857,12 +857,13 @@
|
||||||
"cell_type": "code",
|
"cell_type": "code",
|
||||||
"collapsed": false,
|
"collapsed": false,
|
||||||
"input": [
|
"input": [
|
||||||
|
"from regluit.sysadmin import aws\n",
|
||||||
"iam = aws.boto.connect_iam()\n",
|
"iam = aws.boto.connect_iam()\n",
|
||||||
"\n",
|
"\n",
|
||||||
"# get group names\n",
|
"# get group names\n",
|
||||||
"\n",
|
"\n",
|
||||||
"def all_iam_group_names():\n",
|
"def all_iam_group_names():\n",
|
||||||
" return [g.group_name for g in iam_groups['list_groups_response']['list_groups_result']['groups']]\n",
|
" return [g.group_name for g in iam.get_all_groups()['list_groups_response']['list_groups_result']['groups']]\n",
|
||||||
"\n",
|
"\n",
|
||||||
"# get user names\n",
|
"# get user names\n",
|
||||||
"\n",
|
"\n",
|
||||||
|
@ -928,7 +929,7 @@
|
||||||
"# test -> grab all groups and list of corresponding users\n",
|
"# test -> grab all groups and list of corresponding users\n",
|
||||||
"\n",
|
"\n",
|
||||||
"for g in all_iam_group_names():\n",
|
"for g in all_iam_group_names():\n",
|
||||||
" print g, user_names_for_iam_group(g)"
|
" print g, iam_user_names_for_group(g)"
|
||||||
],
|
],
|
||||||
"language": "python",
|
"language": "python",
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
|
|
Loading…
Reference in New Issue