Hey all,

I was surprised not to find an easy copy-pasteable script online for “how to delete AWS IAM roles & detach policies with AWS CLI in Bash”, so here’s my take. I’ve recently had to run a cleanup of some roles, so this is what I used.

roles=("RoleA" "RoleB"…

--

--

Alexander Papageorgiou

Alexander Papageorgiou

Senior Cloud Engineer @ VanMoof. JVM (Java/Kotlin/Groovy) developer. Founded Thalatta, a SaaS startup https://twitter.com/alkoclick