Last active
April 13, 2021 15:18
-
-
Save nmarley/e8744c74bec155798662478823a55947 to your computer and use it in GitHub Desktop.
Get latest Alpine AMI
This file contains hidden or 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
#! /bin/bash | |
# get latest alpine linux AMI | |
aws ec2 describe-images --output text --filters Name=owner-id,Values=538276064493 Name=name,Values='alpine-ami-3.13*-x86_64*' Name=architecture,Values=x86_64 Name=state,Values=available --query 'max_by(Images[], &CreationDate).ImageId' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment