> ## Documentation Index
> Fetch the complete documentation index at: https://docs.plerion.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Linking target accounts to an AWS service account

> Link AWS target accounts to your service account so CWPP appliances can scan workloads centrally across accounts.

You can link target accounts either when creating new AWS integrations or by updating existing ones.

> [!WARNING]
>
> The service account can only be linked to a target account that is part of the same AWS organization.

A service account that is [awaiting approval](https://docs.plerion.com/guides/integrations/aws/service-account/getting-started-with-aws-service-account.md#service-account-approval) cannot be selected. Approve it first.

***

## Create new target accounts

### Onboard a single AWS account

**1. On the Plerion dashboard, go to Settings > Integrations**

![Sidebar navigation with Settings expanded and Integrations highlighted](https://mintcdn.com/pleriondocs/xqwXbDdIvpJS066S/images/integrations/aws/settings-integrations-sidenav.png?fit=max\&auto=format\&n=xqwXbDdIvpJS066S\&q=85\&s=76e3ee2c20634eb080fc39574d8b029f)

**2. Find AWS account and click the + button**

Click `Add single AWS account` to continue with onboarding a single AWS account.

![Integrations page with AWS account option and plus button to add integration](https://mintcdn.com/pleriondocs/xqwXbDdIvpJS066S/images/integrations/aws/add-aws-account.png?fit=max\&auto=format\&n=xqwXbDdIvpJS066S\&q=85\&s=9f6c5887de7bee6862a253b74bf23d82)

![Integrations page with AWS account option, with the single account option or multi-account option](https://mintcdn.com/pleriondocs/ysQhS5nLnsZHgata/images/integrations/aws/add-aws-account-single-or-multiple.png?fit=max\&auto=format\&n=ysQhS5nLnsZHgata\&q=85\&s=a9a11c868122ac4ee567577ff9ad7e8d)

**3. Select your desired capabilities**

* Select `CSPM`, `CIEM` and `CWPP`
* For the CWPP deployment, choose `Service account` and select your service account.
* Click `Next` to continue.

![Single-account capabilities with CWPP Service account](https://mintcdn.com/pleriondocs/kZep2o9T0iPastk9/images/service-account/link/create-single-account.png?fit=max\&auto=format\&n=kZep2o9T0iPastk9\&q=85\&s=7b78b78ff80f34e55293e197d813394c)

**4. Launch the CloudFormation stack**

Click `Launch stack` to open the **Quick create stack** page in AWS CloudFormation.

![Launch CloudFormation stack for AWS service account](https://mintcdn.com/pleriondocs/xqwXbDdIvpJS066S/images/integrations/aws/launch-cloudformation-stack-for-aws-service-account.png?fit=max\&auto=format\&n=xqwXbDdIvpJS066S\&q=85\&s=cd19accfcdba82f440af9791551b87f4)

**5. Verify the Service account parameter and create the stack**

![CloudFormation with Service account parameter present](https://mintcdn.com/pleriondocs/PiJQmHFPFDcFXL4P/images/service-account/link/create-single-account-stack.png?fit=max\&auto=format\&n=PiJQmHFPFDcFXL4P\&q=85\&s=95b4d8ee34bf160bd928217391ea6332)

**6. After the stack completes, the AWS integration will be created and linked to your AWS service account.**

***

### Onboard multiple AWS accounts using StackSets

**1. On the Plerion dashboard, go to Settings > Integrations**

![Sidebar navigation with Settings expanded and Integrations highlighted](https://mintcdn.com/pleriondocs/xqwXbDdIvpJS066S/images/integrations/aws/settings-integrations-sidenav.png?fit=max\&auto=format\&n=xqwXbDdIvpJS066S\&q=85\&s=76e3ee2c20634eb080fc39574d8b029f)

**2. Find AWS account and click the + button**

Click `Add accounts using Multi-Account Onbooarding` to add mutiple AWS accounts at once.

![Integrations page with AWS account option and plus button to add integration](https://mintcdn.com/pleriondocs/xqwXbDdIvpJS066S/images/integrations/aws/add-aws-account.png?fit=max\&auto=format\&n=xqwXbDdIvpJS066S\&q=85\&s=9f6c5887de7bee6862a253b74bf23d82)

![Integrations page with AWS account option, with the single account option or multi-account option](https://mintcdn.com/pleriondocs/ysQhS5nLnsZHgata/images/integrations/aws/add-aws-account-single-or-multiple.png?fit=max\&auto=format\&n=ysQhS5nLnsZHgata\&q=85\&s=a9a11c868122ac4ee567577ff9ad7e8d)

**3. Select your desired capabilities**

* Select `CSPM`, `CIEM` and `CWPP`
* For the CWPP deployment, choose `Service account` and select your service account.
* Click `Next` to continue.

![Single-account capabilities with CWPP Service account](https://mintcdn.com/pleriondocs/kZep2o9T0iPastk9/images/service-account/link/create-single-account.png?fit=max\&auto=format\&n=kZep2o9T0iPastk9\&q=85\&s=7b78b78ff80f34e55293e197d813394c)

**4. Choose Console or CLI and provide the ServiceAccountId**

* Use the **ServiceAccountId** shown in Plerion.

![ServiceAccountId parameter reference in Plerion guide](https://mintcdn.com/pleriondocs/PiJQmHFPFDcFXL4P/images/service-account/link/create-multi-account-guide-param.png?fit=max\&auto=format\&n=PiJQmHFPFDcFXL4P\&q=85\&s=17b9d066d87c7e728b6caec15717727b)

**5. If adding more accounts later, use Update Existing StackSet**

![Update Existing StackSet flow in Plerion](https://mintcdn.com/pleriondocs/xqwXbDdIvpJS066S/images/integrations/aws/add-aws-updatestackset.png?fit=max\&auto=format\&n=xqwXbDdIvpJS066S\&q=85\&s=380040468dcd599f95cb526250f11874)

**6. After the stack completes, the AWS integration will be created and linked to your AWS service account.**

***

## Update existing target accounts

### Update a single AWS account

**1. Open the AWS account you want to update**

* On the Plerion dashboard, go to `Settings` > `Integrations`, and find the AWS account you want to update
* Click the edit icon next to **Role ARN**

![Integrated AWS account with Role ARN highlighted](https://mintcdn.com/pleriondocs/xqwXbDdIvpJS066S/images/integrations/aws/aws-integration-edit-role-arn.png?fit=max\&auto=format\&n=xqwXbDdIvpJS066S\&q=85\&s=93681a6d5e3289df29040ad26adad40e)

**2. Enable CWPP and select the service account**

In the capabilities list, enable CWPP.\
Under **Deployment strategy**, choose `Service account` and select the service account you created earlier.

![Select Service account for CWPP in single-account update](https://mintcdn.com/pleriondocs/PiJQmHFPFDcFXL4P/images/service-account/link/update-single-account-guide.png?fit=max\&auto=format\&n=PiJQmHFPFDcFXL4P\&q=85\&s=e3b995343201a82de3c1960c134187eb)

**3. Update stack parameters if required**

If the Plerion template shows updated parameters, modify the stack parameters as shown in the guide.

**4. Run the update in Automated mode (recommended)**

* Update the stack using the **AWS Console** or **CLI** by following the instructions in Plerion.
* Automated mode is recommended for simplicity and reliability.

**5. Confirm the integration is updated and linked**

Once the stack update completes, the AWS account integration will be updated and linked to the service account.

### Update multiple AWS accounts

**1. Open the AWS management account integration**

* On the Plerion dashboard, go to `Settings` > `Integrations`, and find the AWS management account you want to update
* Click the edit icon next to **Role ARN**

**2. Select Multi Account Onboarding**

* In the **Edit integration** page, choose `Update using Multi Account Onboarding`.
* On the **Select capabilities** screen, enable `CSPM`, `CIEM`, and `CWPP`.
* Under **Deployment strategy**, select **Service account** and choose the service account you created earlier.

![Selecting service account for CWPP in multi-account update flow](https://mintcdn.com/pleriondocs/kZep2o9T0iPastk9/images/service-account/link/create-single-account.png?fit=max\&auto=format\&n=kZep2o9T0iPastk9\&q=85\&s=7b78b78ff80f34e55293e197d813394c)

**3. Open Update Existing StackSet and follow the guide**

Switch to the **Update Existing StackSet** tab and follow the instructions provided in Plerion.

![Update Existing StackSet guide in Plerion](https://mintcdn.com/pleriondocs/2HBIdIEF_iUoBKh-/images/service-account/link/update-multi-account-guide.png?fit=max\&auto=format\&n=2HBIdIEF_iUoBKh-\&q=85\&s=bb69cfd65d3018425f05488999f53389)

**4. Provide the ServiceAccountId parameter**

When prompted, enter the **ServiceAccountId** shown in the guide.

![ServiceAccountId parameter in update guide](https://mintcdn.com/pleriondocs/PiJQmHFPFDcFXL4P/images/service-account/link/update-multi-account-guide-param.png?fit=max\&auto=format\&n=PiJQmHFPFDcFXL4P\&q=85\&s=77c574113161daa83b862b48ea73d089)

**5. Run the update in Automated mode (recommended)**

* Complete the update using the **AWS Console** or **CLI**, as instructed in Plerion.
* Automated mode is recommended for simplicity and reliability.

**6. Confirm integrations are updated and linked**

Once the StackSet finishes, both existing and new AWS account integrations will be updated and linked to the service account.

***

## Verify the link

On the Plerion dashboard, go to `Settings` → `Integrations` and open the AWS account integration.\
The integration will show the linked **Service account**, and CWPP scans will appear once they begin.

![AWS integration page showing linked service account](https://mintcdn.com/pleriondocs/kZep2o9T0iPastk9/images/service-account/link/target-account-enabled.png?fit=max\&auto=format\&n=kZep2o9T0iPastk9\&q=85\&s=cbba087c910874ac62e459bfd7dbc3cf)

![CWPP Asset Scans section showing recent scans](https://mintcdn.com/pleriondocs/kZep2o9T0iPastk9/images/service-account/link/target-account-scans.png?fit=max\&auto=format\&n=kZep2o9T0iPastk9\&q=85\&s=b5cfa393d5e452c00ba9ae4f7d2ca41b)

***

## Additional resources created

* **`PlerionApplianceRole` (IAM role in the target account):** Assumed by service account appliances to run scans in the target account.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.