Connect an AWS account
Early Access release
AWS Server Discovery connects one or more AWS accounts to a project so Advanced Server Access can automatically add or remove AWS servers. A project can connect to multiple AWS accounts, but an AWS account can only be associated with a single project across all Advanced Server Access teams.
Advanced Server Access also uses an Okta-managed service account (referred to as an External ID) to interrogate your AWS accounts. These service accounts are unique to each connected cloud account and are used to discover active EC2 instances and any associated metadata. These accounts require minimal read permissions granted via an AWS IAM role. For more information on IAM roles, see the AWS documentation.
An AWS IAM role is required for Server Discovery and Cloud Auto-enrollment to work correctly.
- Identify your AWS account ID.
- Go to the Amazon Web Services management console
- At the top of the page, select the dropdown menu next to your profile name and click My Account.
- Under Account Settings, note your account ID number.
- Configure the project.
- Go to the Advanced Server Access admin console.
- Go to the Projects page and select a project for your server.
- Open the Enrollment tab.
- Click Link Cloud Account.
- From the Create Cloud Account window, configure the cloud account settings.
Setting Action Cloud Provider Select Amazon Web Services. Account ID Enter the account ID you noted earlier. Description Enter a description to help identify the connection. AWS ASA Account ID & External ID Note these values for use in the next step. These are related to an Okta-managed AWS service account and differ from your AWS Account ID.
For details on using an External ID, see the AWS documentation.
- Identify your AWS account ID.
- In a new browser window, access the Amazon Web Services management console and open the IAM console.
Note: Do not close the Create Cloud Account window. - Go to the Roles page and click Create role.
- From the Create Role window, choose the Another AWS account role type.
- Under Account ID, enter the AWS ASA Account ID you noted from the previous step.
- Select Require external ID and enter the External ID you noted from the previous step.
- Click Next: Permissions.
- Grant
AmazonEC2ReadOnlyAccess
permissions to the role.
Note: You can alternatively click Create Policy to create a new custom policy. Your custom policy must include the following:{"Effect": "Allow", "Action": "ec2:Describe*", "Resource": "*"}
For details, see the AWS documentation. - Click Next: Tags.
- Click Next: Review.
- Review the settings and click Create role.
- Note the Amazon Resource Name (ARN) for later use.
- In a new browser window, access the Amazon Web Services management console and open the IAM console.
- Return to the Advanced Server Access Create Cloud Account window.
- In the Role field, enter the ARN.
- Click Submit.
Advanced Server Access connects the cloud account to the project and discovers any active EC2 instances. The discovery process runs daily at roughly the same time the cloud account was originally connected. This continues until the cloud account is disconnected from the project.
You must install the Advanced Server Access server agent on an instance to actually enroll it in a project. Until the server is enrolled, users cannot connect to the server through Advanced Server Access and some server details may not sync correctly.
You can use an enrollment token from a different project, to redeploy the server from the AWS-connected project. This is sometimes done in situations where a server administrator for a discovered AWS server is part of an Advanced Server Access group associated with another project.