Created
December 6, 2019 03:17
-
-
Save GeneralTesler/065bcf3ef24ba01d6196d4bc9ae6b9a9 to your computer and use it in GitHub Desktop.
boto3 list users via resource handler
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import boto3 | |
if __name__ == "__main__": | |
session = boto3.session.Session() | |
resource = session.resource("iam") | |
[print(r.arn) for r in getattr(resource, "users").all()] | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment