From 4d8230ba40b21d2d446693ab169b72b4bf3a659d Mon Sep 17 00:00:00 2001 From: badra001 Date: Fri, 17 Jul 2026 16:02:58 -0400 Subject: [PATCH] initial --- .../run.check_cloudtrail.sh | 54 +++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100755 local-app/python-tools/cross-organization/run.check_cloudtrail.sh diff --git a/local-app/python-tools/cross-organization/run.check_cloudtrail.sh b/local-app/python-tools/cross-organization/run.check_cloudtrail.sh new file mode 100755 index 00000000..5e6cfbc0 --- /dev/null +++ b/local-app/python-tools/cross-organization/run.check_cloudtrail.sh @@ -0,0 +1,54 @@ +#!/bin/bash + +VERSION="1.0.0" +export PYTHONUNBUFFERED=1 + +if [ -z "$1" ] +then + ORG="ent-gov" +else + ORG="$1" +fi + +WORKERS=8 +if [ "$ORG" == "ent-gov" ] +then + REGION="us-gov-east-1" + REGIONS="us-gov-east-1 us-gov-west-1" + WORKERS=16 +fi +if [ "$ORG" == "lab-gov" ] +then + REGION="us-gov-east-1" + REGIONS="us-gov-east-1 us-gov-west-1" +fi +if [ "$ORG" == "ent-ew" ] +then + REGION="us-east-1" + REGIONS="us-east-1 us-east-1 us-west-1 us-west-2" + WORKERS=16 +fi + +if [ ! -z "$2" ] +then + REGION="$2" +fi + +CHECK="check_cloudtrail" + +if [ $CHECK == "NAME" ] +then + echo "* configure for the appropriate check" + exit 1 +fi + +# --dry-run +# --no-logfile +echo "* executing for ORG $ORG region $REGION check $CHECK workers $WORKERS" +./org_runner3.py --profile $ORG.org --region $REGION \ + --progress-account \ + --role-name r-inf-org-controller \ + --output \ + --module $CHECK \ + --regions $REGIONS \ + --max-workers $WORKERS