Difference between revisions of "Amazon CloudWatch Logs groups"

From wikieduonline
Jump to navigation Jump to search
Line 3: Line 3:
 
[[ChatGPT]]:
 
[[ChatGPT]]:
 
  for log_stream_name in $(aws logs describe-log-streams --log-group-name <log-group-name> --output text --query  
 
  for log_stream_name in $(aws logs describe-log-streams --log-group-name <log-group-name> --output text --query  
  'logStreams[*].logStreamName'); do aws logs get-log-events --log-group-name <log-group-name> --log-stream-name  
+
  'logStreams[*].logStreamName'); do [[aws logs get-log-events]] --log-group-name <log-group-name> --log-stream-name  
 
  $log_stream_name --output text --query 'events[*].message' >> all_logs.txt; done
 
  $log_stream_name --output text --query 'events[*].message' >> all_logs.txt; done
  

Revision as of 16:08, 3 May 2023

Advertising: