pacbot icon indicating copy to clipboard operation
pacbot copied to clipboard

Adding New AWS Accounts to PacBot

Open artdanad opened this issue 7 years ago • 4 comments

❔ Question

No data from Client account. All I see in dashboard is only data from Base account.

🔦 Context

I strongly followed instructions how to add new Client account, but don't see any data from client account in dashboard. It's been already more than 24 hours, but in PacBot I see data only from Base account, Statistics dashboard also show that only 1 AWS account was scanned. Is there another place where I can look for some errors? I also checked client account IAM role Access advisor, and looks like it's never used(All services are never accessed).

Aha! Link: https://t-mobile1t-mobile.aha.io/features/PM-349

artdanad avatar Apr 25 '19 09:04 artdanad

Same for me as well, But I'm bit confused about the cloud watch cross-account rules. I have updated the installer/data/terraform/lambda_submit_function_DataCollectorCloudWatchEventTarget.tf input json with {"encrypt":false,"value":"${data.aws_caller_identity.data_aws_info_AwsAccount.account_id}, Client_Account_ID_2","key":"accountinfo"} and redeployed. Still no luck. can you please mention in which file we should add the cross-account id?

amalcp avatar Apr 25 '19 13:04 amalcp

@amalcp I don't think You should mess with deployment files. According to documentation, You should do 3 things:

  1. Create pacbot_ro role in Client, and allow base account role pacbot_ro to assume this role.
  2. Update pacbot_ro policy in base account by adding role ARN from client account.
  3. Edit CloudWatch rule pacbot-AWS-Data-Collector, Constant (JSON text) to include Your client account. Wait 1 hour for this rule to execute.

At least I did all those actions but still don't see data from 2 added client accounts. :(

artdanad avatar Apr 25 '19 13:04 artdanad

Hey @amalcp & @artdanad , Could you please join to the PacBot gitter? So that we can do a quick troubleshoot.

johnakash avatar Apr 25 '19 17:04 johnakash

I want to say big thanks to @johnakash for help. My issue was that I didn't assigned pacbot_ro policy to pacbot_ro role in Base account. I hope it helps someone to troubleshoot issue.

artdanad avatar Apr 25 '19 22:04 artdanad