Skip to content

creating a python script that checks the default AWS account and upload the log to ELK

Notifications You must be signed in to change notification settings

ydekel6/full-cycle

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 

Repository files navigation

USAGE

This code is meant to get EC2 info from the default AWS account and region that is set in ~/.aws/credentials.

Moreover, this code creates a basic statistics report of your EC2 running instances and usage and sends it to sdtout as a JSON.

The Filters is set to pull information from all running EC2 instances, but you can change it in the following line:

instances = ec2.describe_instances(Filters=[{'Name' : 'instance-state-name','Values' : ['running']}])

LIMITATIONS

  • This code expects you to have an AWS account and credentials set-up as to documentations shows.
  • As said, this code doesn't handle several accounts or several regions.
  • Some of the fields are static (name,threadName,message and levelname).

About

creating a python script that checks the default AWS account and upload the log to ELK

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published