Skip to content

Commit

Permalink
Add orgs import params
Browse files Browse the repository at this point in the history
  • Loading branch information
iann0036 committed Nov 18, 2023
1 parent 7e6a52e commit 3584433
Showing 1 changed file with 14 additions and 3 deletions.
17 changes: 14 additions & 3 deletions js/services/organizations.js
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,10 @@ service_mapping_functions.push(function(reqParams, obj, tracked_resources){
'terraformType': 'aws_organizations_organizational_unit',
'options': reqParams,
'returnValues': {
'Ref': obj.data.Id
'Ref': obj.data.Id,
'Import': {
'Id': obj.data.Id
}
}
});
} else if (obj.type == "organizations.account") {
Expand Down Expand Up @@ -443,7 +446,10 @@ service_mapping_functions.push(function(reqParams, obj, tracked_resources){
'terraformType': 'aws_organizations_account',
'options': reqParams,
'returnValues': {
'Ref': obj.data.Id
'Ref': obj.data.Id,
'Import': {
'AccountId': obj.data.Id
}
}
});
} else if (obj.type == "organizations.policy") {
Expand Down Expand Up @@ -472,7 +478,12 @@ service_mapping_functions.push(function(reqParams, obj, tracked_resources){
'service': 'organizations',
'type': 'AWS::Organizations::Policy',
'terraformType': 'aws_organizations_policy',
'options': reqParams
'options': reqParams,
'returnValues': {
'Import': {
'Id': obj.data.PolicySummary.Id
}
}
});
} else if (obj.type == "organizations.policyattachment") {
reqParams.tf['policy_id'] = obj.data.PolicyId;
Expand Down

0 comments on commit 3584433

Please sign in to comment.