AWS CloudTrail CLI example(delete ECS service event)

AWS/AWS CloudTrail

  • CLI
aws cloudtrail lookup-events --lookup-attributes AttributeKey=<attribute>,AttributeValue=<string>
  • attribute
AccessKeyId
EventId
EventName
EventSource
ReadOnly
ResourceName
ResourceType
Username
  • delete ECS service event (example)
aws cloudtrail lookup-events --lookup-attributes AttributeKey=EventName,AttributeValue=DeleteService --query Events[].Resources[].ResourceName
  • reference

https://docs.aws.amazon.com/ko_kr/awscloudtrail/latest/userguide/view-cloudtrail-events-cli.html