diff --git a/ec2-create-ce b/ec2-create-ce index 84950c3..2c3e040 100755 --- a/ec2-create-ce +++ b/ec2-create-ce @@ -88,10 +88,10 @@ copy_ami() { fi if $_opt_public ; then - echo "Marking AMI $ami_id as public" - ec2-modify-image-attribute --region "$target_region" "$ami_id" --launch-permission -a all + echo "Marking AMI $ami_id_copy as public" + ec2-modify-image-attribute --region "$target_region" "$ami_id_copy" --launch-permission -a all if [ $? -ne 0 ] ; then - echo "Noticed problem when trying to mark AMI with ID $ami_id in region $target_region as public." >&2 + echo "Noticed problem when trying to mark AMI with ID $ami_id_copy in region $target_region as public." >&2 return 1 fi fi