Class: AWSCDK::Organizations::CfnAccountProps
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::Organizations::CfnAccountProps
- Defined in:
- organizations/cfn_account_props.rb
Overview
Properties for defining a CfnAccount.
Instance Attribute Summary collapse
-
#account_name ⇒ String
readonly
The account name given to the account when it was created.
-
#email ⇒ String
readonly
The email address associated with the AWS account.
-
#parent_ids ⇒ Array<String>?
readonly
The unique identifier (ID) of the root or organizational unit (OU) that you want to create the new account in.
-
#role_name ⇒ String?
readonly
The name of an IAM role that AWS Organizations automatically preconfigures in the new member account.
-
#tags ⇒ Array<AWSCDK::CfnTag>?
readonly
A list of tags that you want to attach to the newly created account.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(account_name:, email:, parent_ids: nil, role_name: nil, tags: nil) ⇒ CfnAccountProps
constructor
A new instance of CfnAccountProps.
- #to_jsii ⇒ Object
Constructor Details
#initialize(account_name:, email:, parent_ids: nil, role_name: nil, tags: nil) ⇒ CfnAccountProps
Returns a new instance of CfnAccountProps.
14 15 16 17 18 19 20 21 22 23 24 25 |
# File 'organizations/cfn_account_props.rb', line 14 def initialize(account_name:, email:, parent_ids: nil, role_name: nil, tags: nil) @account_name = account_name Jsii::Type.check_type(@account_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "accountName") @email = email Jsii::Type.check_type(@email, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "email") @parent_ids = parent_ids Jsii::Type.check_type(@parent_ids, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "parentIds") unless @parent_ids.nil? @role_name = role_name Jsii::Type.check_type(@role_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "roleName") unless @role_name.nil? @tags = .is_a?(Array) ? .map { |jsii_v0| jsii_v0.is_a?(Hash) ? ::AWSCDK::CfnTag.new(**jsii_v0.transform_keys(&:to_sym)) : jsii_v0 } : Jsii::Type.check_type(@tags, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLkNmblRhZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "tags") unless @tags.nil? end |
Instance Attribute Details
#account_name ⇒ String (readonly)
The account name given to the account when it was created.
31 32 33 |
# File 'organizations/cfn_account_props.rb', line 31 def account_name @account_name end |
#email ⇒ String (readonly)
The email address associated with the AWS account.
The regex pattern for this parameter is a string of characters that represents a standard internet email address.
38 39 40 |
# File 'organizations/cfn_account_props.rb', line 38 def email @email end |
#parent_ids ⇒ Array<String>? (readonly)
The unique identifier (ID) of the root or organizational unit (OU) that you want to create the new account in.
If you don't specify this parameter, the ParentId defaults to the root ID.
This parameter only accepts a string array with one string value.
The regex pattern for a parent ID string requires one of the following:
- Root - A string that begins with "r-" followed by from 4 to 32 lowercase letters or digits.
- Organizational unit (OU) - A string that begins with "ou-" followed by from 4 to 32 lowercase letters or digits (the ID of the root that the OU is in). This string is followed by a second "-" dash and from 8 to 32 additional lowercase letters or digits.
52 53 54 |
# File 'organizations/cfn_account_props.rb', line 52 def parent_ids @parent_ids end |
#role_name ⇒ String? (readonly)
Default: - "OrganizationAccountAccessRole"
The name of an IAM role that AWS Organizations automatically preconfigures in the new member account.
This role trusts the management account, allowing users in the management account to assume the role, as permitted by the management account administrator. The role has administrator permissions in the new member account.
If you don't specify this parameter, the role name defaults to OrganizationAccountAccessRole .
For more information about how to use this role to access the member account, see the following links:
- Creating the OrganizationAccountAccessRole in an invited member account in the AWS Organizations User Guide
- Steps 2 and 3 in IAM Tutorial: Delegate access across AWS accounts using IAM roles in the IAM User Guide
The regex pattern that is used to validate this parameter. The pattern can include uppercase letters, lowercase letters, digits with no spaces, and any of the following characters: =,.@-
69 70 71 |
# File 'organizations/cfn_account_props.rb', line 69 def role_name @role_name end |
#tags ⇒ Array<AWSCDK::CfnTag>? (readonly)
A list of tags that you want to attach to the newly created account.
For each tag in the list, you must specify both a tag key and a value. You can set the value to an empty string, but you can't set it to null . For more information about tagging, see Tagging AWS Organizations resources in the AWS Organizations User Guide.
If any one of the tags is not valid or if you exceed the maximum allowed number of tags for an account, then the entire request fails and the account is not created.
78 79 80 |
# File 'organizations/cfn_account_props.rb', line 78 def @tags end |
Class Method Details
.jsii_properties ⇒ Object
80 81 82 83 84 85 86 87 88 |
# File 'organizations/cfn_account_props.rb', line 80 def self.jsii_properties { :account_name => "accountName", :email => "email", :parent_ids => "parentIds", :role_name => "roleName", :tags => "tags", } end |
Instance Method Details
#to_jsii ⇒ Object
90 91 92 93 94 95 96 97 98 99 100 |
# File 'organizations/cfn_account_props.rb', line 90 def to_jsii result = {} result.merge!({ "accountName" => @account_name, "email" => @email, "parentIds" => @parent_ids, "roleName" => @role_name, "tags" => @tags, }) result.compact end |