Skip to content

bahrmichael/aws-service-tagger

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Service Tagger for AWS

Read the companion article

❗ Supported Services

  • lambda
  • cloudwatchlogs
  • cloudfront

Let us know which services you are interested in!

🏭 Install dependencies

pip install -r requirements.txt

📐 Config structure

The yaml config specifies which tags and which functions should get which tag values.

Structure

target_tag:
    tag_value:
      - arn_part

The target_tag specifies the key of the tag. The tag_value specifies the value of the tag. This tag is applied to every resource of the given service whose ARN contains the arn_part.

Example

department:
  research:
    - aws-scheduler
    - stock-watch
    - bottleneck-testing
    - testing-mail
  business:
    - market-watch
    - contracts-appraisal
project:
  scheduler:
    - aws-scheduler
    - bottleneck-testing
  stock-watch:
    - stock-watch
  mail:
    - testing-mail
  market-watch:
    - market-watch
  contracts-appraisal:
    - contracts-appraisal

🚀 Run

  • Show the help: python tagger.py --help
  • Show existing tags: python tagger.py lambda TAG_1,TAG_2,TAG_N
  • Use the region eu-central-1 instead of the default us-east-1: python tagger.py lambda TAG --region eu-central-1
  • Do a dry run for writing new tags: python tagger.py lambda TAG --write --dry-run
  • Use a different yaml file than tag_config.yarml: python tagger.py lambda TAG --write --file my_config.yaml
  • Overwrite existing tags: python tagger.py lambda TAG --write --overwrite

🔧 Contributions

Yes please! Open a ticket or send a pull request.

About

A tool to retroactively tag AWS services.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages