Switch a Vultr IAM role type with PUT /v2/roles/{id} and role_type; bundled policies are preserved.
Yes. An assignable role can be converted to an assumable role and vice versa via the Vultr API using the Update Role endpoint. The permission policies bundled in the role are preserved during conversion, only the access pattern changes.
To convert a role, send a PUT request to /v2/roles/{id} with the role_type field set to either assignable or assumable:
To convert the role back, set role_type to assignable. The max_session_duration field applies only to assumable roles and is optional. If omitted, it defaults to 3,600 seconds (1 hour). When specified, the value must be between 900 seconds (15 minutes) and 43,200 seconds (12 hours).
Before an assumable role can be used, you must create a role trust that defines who can assume it. The user assuming the role also needs the iam.role.AssumeRole, iam.role.Read, and iam.assumedrole.Read permissions.
Only assignable roles can be attached to groups. Assumable roles cannot be attached to groups, so review any group assignments before converting a role.
0 Comments
Be the first to comment and share your perspective with the community.