Manage the AWS reader role in infrastructure code
Choose Infrastructure code on the AWS connection’s Setup tab when your team manages account roles with Terraform, SST or Pulumi.
Integrate the account-wide role into one stack#
For your own infrastructure code, select Terraform, SST v3, or Pulumi (TypeScript). The generated provider restricts the target account and includes your region. Use one stack or stage to manage this account-wide role. Do not deploy the same role from every application stage. If your pipeline configures provider role assumption or tags separately, preserve those approved settings when integrating the provider.
For SST v3, place the block inside run() in sst.config.ts, or a module that run() calls. SST supplies the aws namespace. Keep your existing app, stage and state configuration. For standalone Pulumi TypeScript, the block imports @pulumi/aws.
Review and apply the change through your authorized deployment process. A successful plan or preview does not create the role.