Explorar o código

add py/IAM-Create.py.

xdc %!s(int64=5) %!d(string=hai) anos
pai
achega
d78f20c30a
Modificáronse 1 ficheiros con 11 adicións e 0 borrados
  1. 11 0
      py/IAM-Create.py

+ 11 - 0
py/IAM-Create.py

@@ -0,0 +1,11 @@
+import boto3
+client  = boto3.client('iam')
+
+client.create_user(UserName='heheda')
+
+response = client.attach_user_policy(
+    UserName='heheda',
+    PolicyArn='arn:aws-cn:iam::aws:policy/AdministratorAccess')
+
+client.create_login_profile(UserName='heheda',Password='heheda')
+