Installing Plerion infrastructure on a Service account

Installation of Plerion infrastructure is a two-step process:

  1. Setting up the permissions required to run the Plerion infrastructure
  2. Installing the Plerion infrastructure in applicable regions

Setting up the permissions required

Steps for setting up permissions

Follow the steps below to set up the permissions required to run the Plerion infrastructure.

  1. On the Plerion Dashboard, Click on Tenant Settings and click on Integrations
  2. Search for Service Account Navigate
  3. Click on the + button on the integration tile that says Workload AWS Service Account
  4. Follow the steps in the wizard to create a new service account using AWS CloudFormation.
  5. Once the CloudFormation stack is created, the service account is automatically created. Returning to the Plerion Dashboard will take you to the Service Account List page. Service Account Details
  6. Click on the service account name to view the details of the service account. Service Account Details
  7. Configure regions where you want to install the Plerion infrastructure by following the steps in the next section.

Limitations

  1. An AWS account can only be associated with one service account.
  2. Service accounts cannot be shared across tenants in the same Plerion organization or across different Plerion organizations.
  3. The max number of service accounts that can be created in a tenant is 10.

Resources Created

Installing the CloudFormation template will create the following resources:

ResourceResource TypeDescription
PlerionWorkloadAccessRoleAWS::IAM::RoleThe role that will be assumed by Plerion Control Plane to manage the service account. The role grants necessary permissions to manage the appliance and clean up resources.
PlerionWorkloadAccessPolicyAWS::IAM::ManagedPolicyThe policy that will be attached to the PlerionWorkloadAccessRole to allow Plerion Control Plane to manage the service account.
PlerionInstanceProfileRoleAWS::IAM::RoleThe role that will be attached to the appliance instance to allow the instance to assume the Target account roles.
PlerionInstanceProfileAWS::IAM::InstanceProfileThe instance profile that uses the PlerionInstanceProfileRole.
PlerionAPICallFunctionAWS::Lambda::FunctionThe Lambda function will be used to call the Plerion API to create the service account automatically.
PlerionAPILambdaExecutionRoleAWS::IAM::RoleThe role that will be attached to the PlerionAPICallFunction to allow the function to call the Plerion API.
PlerionAPICallCustom::PlerionAPICallCustom resource to call the Plerion API to create the service account automatically.

Troubleshooting

Error: PlerionInstanceProfileRole already exists in the stack

Service Account Details

This error occurs when the AWS account is already being used as a service account in an existing Plerion organization. Currently, an AWS account can only be associated with one service account. To resolve this error, either delete the existing service account and the stack associated or use a different AWS account.

Installing the Plerion infrastructure in applicable regions

Install the Plerion infrastructure in the regions where you want to run the Plerion workload scans. Follow the steps below to install the Plerion infrastructure in applicable regions.

Steps for setting up permissions

  1. On the Service Account Dashboard, Click on Enable Region Service Account Details
  2. Select the region where you want to install the Plerion infrastructure and click on Launch Stack Service Account Details
  3. Follow the steps in the wizard to install the Plerion infrastructure in the selected region.
  4. Once the CloudFormation stack is created, the Plerion infrastructure is automatically installed in the selected region. Returning to the Service Account Dashboard shows the region as enabled. Service Account Details
  5. Repeat the steps above to install the Plerion infrastructure in other regions.
  6. Once the Plerion infrastructure is installed in all the regions where you want to run the Plerion workload scans, you can start linking target accounts to the service account by following the steps in the Linking target accounts to the service accounts.

Resources Created

Installing the CloudFormation template will create the following resources:

ResourceResource TypeDescription
ElasticIpAZ1AWS::EC2::EIPThe Elastic IP address for the NAT Gateway.
InternetGatewayAWS::EC2::InternetGatewayAllow the VPC to access the internet.
NatGatewayAZ1AWS::EC2::NatGatewayThe NAT Gateway allows the private subnet to access the internet securely
PlerionAPICallCustom::PlerionAPICallCustom resource to call the Plerion API to create the service account automatically.
PlerionAPICallFunctionAWS::Lambda::FunctionThe Lambda function will be used to call the Plerion API to create the service account automatically.
PlerionAPILambdaExecutionRoleAWS::IAM::RoleThe role that will be attached to the PlerionAPICallFunction to allow the function to call the Plerion API.
PlerionApplianceAutoScalingGroupAWS::AutoScaling::AutoScalingGroupThe AutoScaling group that will be used to manage the appliance instances.
PlerionApplianceLaunchLifecycleHookAWS::AutoScaling::LifecycleHookThe lifecycle hook that will be used to manage the appliance instances.
PlerionApplianceLaunchTemplateAWS::EC2::LaunchTemplateThe launch template that will be used to launch the appliance instances.
PlerionApplianceQueueBacklogNoInstancesAWS::CloudWatch::AlarmThe alarm that will be used to scale out the appliance instances.
PlerionApplianceQueueBacklogPerInstanceScaleInAWS::CloudWatch::AlarmThe alarm that will be used to terminate appliances when the queue has a smaller backlog
PlerionApplianceQueueBacklogPerInstanceScaleOutAWS::CloudWatch::AlarmThe alarm that will be used to scale out the appliance instances when the workload scan queue has a backlog.
PlerionApplianceQueueNoBacklogWithInstancesScaleInAWS::CloudWatch::AlarmThe alarm that will be used to terminate appliances when the queue has no backlog.
PlerionApplianceScanQueueAWS::SQS::QueueThe queue that will be used to manage the workload scan queue.
PlerionApplianceSecurityGroupAWS::EC2::SecurityGroupThe security group that will be used to manage the appliance instances. The security group allows outbound access to allow the appliance to scan and send results
PlerionApplianceSubnetAZ1PrivateAWS::EC2::SubnetThe private subnet that will be used to launch the appliance instances.
PlerionApplianceTerminationLifecycleHookAWS::AutoScaling::LifecycleHookThe lifecycle hook that will be used to manage the appliance instances.
PlerionApplianceVPCAWS::EC2::VPCThe VPC that will be used to launch the appliance instances.
PlerionKmsKeyAWS::KMS::KeyThe KMS key that will be used to encrypt the resources being copied from the target accounts.
PlerionScaleInPolicyAWS::AutoScaling::ScalingPolicyThe policy that will be used to terminate appliances when the queue has no backlog.
PlerionScaleOutPolicyAWS::AutoScaling::ScalingPolicyThe policy that will be used to scale out the appliance instances when the workload scan queue has a backlog.
PlerionSubnetAZ1PublicAWS::EC2::SubnetThe public subnet that will be used to host the NAT Gateway.
RouteTableAssociationAZ1PrivateAWS::EC2::SubnetRouteTableAssociationThe association between the private subnet and the private route table.
RouteTableAZ1PrivateCommonAWS::EC2::RouteTableThe private route table that will be used to route traffic to the NAT Gateway.
RouteTableAZ1PublicAWS::EC2::RouteTableThe public route table that will be used to route traffic to the internet.
RouteTableAZ1PublicSubnetAssociationAWS::EC2::SubnetRouteTableAssociationThe association between the public subnet and the public route table.
RouteTablePrivateCommonAZ1InternetRouteAWS::EC2::RouteThe route that will be used to route traffic to the internet via NAT Gateway.
RouteTablePublicAZ1InternetRouteAWS::EC2::RouteThe route that will be used to route traffic to the internet.
ServiceAccountOrganizationCustom::RetrieveOrganizationIdFunctionCustom resource to retrieve the organization ID from the current AWS account.
ServiceAccountOrganizationFunctionAWS::Lambda::FunctionThe Lambda function will be used to retrieve the organization ID from the current AWS account.
ServiceAccountOrganizationFunctionExecutionRoleAWS::IAM::RoleThe role that will be attached to the ServiceAccountOrganizationFunction to allow the function to retrieve the organization ID from the current AWS account.
VPCGatewayAttachmentAWS::EC2::VPCGatewayAttachmentThe attachment between the VPC and the Internet Gateway.

Troubleshooting

Error: Resource handler returned message: "Resource of type 'AWS::SQS::Queue' with identifier 'plerion-appliance-scan-queue' already exists

Region Duplicate Error

This error occurs when the region where you are trying to install the Plerion infrastructure already has a Plerion infrastructure installed. To resolve this error, you can either delete the existing Plerion infrastructure or install the Plerion infrastructure in a different region. If the installation wasn't intended in the same region, delete the failed stack.