Setting the Default Version of a Managed Policy
You can choose which policy version you want to apply to the EIM identities (users or groups) the policy is attached to. You can set another policy version as the default one at any time.
To set the default version of a managed policy, use the set-default-policy-version command following this syntax:
$ aws iam set-default-policy-version \
--profile YOUR_PROFILE \
--policy-arn arn:aws:iam::123456789012:policy/my-policy \
--version-id v2 \
This command contains the following attributes that you need to specify:
profile: The named profile you want to use, created when configuring AWS CLI. For more information, see Installing and Configuring AWS CLI.
policy-arn: The OUTSCALE Resource Name (ORN) of the policy.
version-id: The ID of the policy version you want to set as default.
endpoint: The endpoint corresponding to the Region you want to send the request to.
The specified policy version is set as the default one and is applied to the EIM identities the policy is attached to.
Corresponding API Method
AWS™ and Amazon Web Services™ are trademarks of Amazon Technologies, Inc or its affiliates in the United States and/or other countries.