Current File : //usr/lib/python2.7/site-packages/euca2ools/commands/iam/addrolepolicy.pyo
�
��Xc@srddlZddlmZddlmZmZmZddlmZddl	m
Z
defd��YZdS(i����N(tArg(t
IAMRequestt
AS_ACCOUNTtarg_role(t
PutRolePolicy(tbuild_iam_policyt
AddRolePolicycBs�eZdZedd�edddddedd�ed	d
dd dedd�edddddddedd�edddddddedd�edddddd�egZd�Zd�Z	RS(!sqAdd a new policy to a role.  To add more complex policies than this tool supports, see euare-roleuploadpolicy(1).thelps'role to attach the policy to (required)s-ps
--policy-nametmetavartPOLICYtrequireds!name of the new policy (required)s-es--effecttchoicestAllowtDenys6whether the new policy should Allow or Deny (required)s-as--actiontdesttactionstactiontappendsLaction(s) the policy should apply to
                (at least one required)s-cs
--resourcet	resourcessNresource(s) the policy should apply to
                (at least one required)s-os--outputt
store_trues%also display the newly-created policycCs�t|jd|jd|jd�}tj|�}tj|d|jdd|jdd|d|jd�}|j�}||d<|S(	NteffectRRtRoleNamet
PolicyNametpolicy_nametPolicyDocumenttDelegateAccount(RtargstjsontdumpsRt
from_othertparamstmain(tselftpolicyt
policy_doctreqtresponse((sH/usr/lib/python2.7/site-packages/euca2ools/commands/iam/addrolepolicy.pyR5s

cCs|jdr|dGHndS(NtoutputR(R(R tresult((sH/usr/lib/python2.7/site-packages/euca2ools/commands/iam/addrolepolicy.pytprint_resultBs
(RR
(
t__name__t
__module__tDESCRIPTIONRRtTrueRtARGSRR'(((sH/usr/lib/python2.7/site-packages/euca2ools/commands/iam/addrolepolicy.pyR#s"		
(RtrequestbuilderRteuca2ools.commands.iamRRRt$euca2ools.commands.iam.putrolepolicyRteuca2ools.utilRR(((sH/usr/lib/python2.7/site-packages/euca2ools/commands/iam/addrolepolicy.pyt<module>s