Cloud AWS

From WTFwiki
Revision as of 11:52, 19 October 2022 by Jontow (talk | contribs) (add taggingapi hints)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Tagging

When auditing tags in use or planning tag policies, aws cli provides helpful tagging api commands:

  • Get all tag keys used in an account:
 $ aws resourcegroupstaggingapi get-tag-keys
 {
     "TagKeys": [
         "App",
         "Contact1",
  ...
 }
  • Get all permutations (values) for a single tag key used in an account:
 $ aws resourcegroupstaggingapi get-tag-values --key App
 {
     "TagValues": [
         "app1",
         "someapp-dev1",
         "console-dev1",
  ...
 }