Created
April 18, 2023 20:00
-
-
Save jailbirt/d62489ecf5a9cc181c1d6ae7c12599f0 to your computer and use it in GitHub Desktop.
Move AWS Launch Templates from one region to another.
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
#!/bin/bash | |
if [ -z $1 ];then | |
echo please provide the launch template to copy from | |
exit 0 | |
fi | |
aws ec2 describe-launch-template-versions --launch-template-id $1 > $1.json | |
echo old template was saved as $1.json modify it and create the new one by running: | |
echo aws ec2 create-launch-template --launch-template-name MyNewLaunchTemplateName --version-description "Initial version" --cli-input-json file://$1.json |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment