fixed some names for IAM code

pull/1/head
Raymond Yee 2013-06-10 16:44:49 -07:00
parent b398a21cc8
commit 43f300de99
1 changed files with 3 additions and 2 deletions

View File

@ -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": {},