List all AWS AMI names through CLI?

Question:

I want to write a script that prints out all the AMIs created before (or after) a certain date. However, I am really struggling to do this so any help is sincerely appreciated.

I don’t have much now, but this is what I have so far:

Any tips on how to filter out just for the AMIs created before a certain date?

Answer:

Here’s an example that queries for all images created after April 1st, 2016:

I believe you should be able to expand on that example to get everything you need.

Leave a Reply