When not including termination_list parameter:
TASK: [Delete template API instance] ******************************************
failed: [localhost → 127.0.0.1] => {“failed”: true}
msg: termination_list needs to be a list of instances to terminate
FATAL: all hosts have already failed – aborting
So I include termination_list and:
TASK: [Delete template API instance] ******************************************
failed: [localhost → 127.0.0.1] => {“failed”: true}
msg: unsupported parameter for module: termination_list
FATAL: all hosts have already failed – aborting
Config is:
{
“name”: “Delete template API instance”,
“local_action”: {
“module”: “ec2”,
“region”: “us-east-1”,
“state”: “absent”,
“wait”: “yes”,
“assign_public_ip”: “no”,
“count”: 1,
“ebs_optimized”: “no”,
“image”: “ami-f11ac69a”,
“instance_tags”: {
“Name”: “{{ xaos_template_instance_name }}”
},
“instance_type”: “t2.micro”,
“key_name”: “juju-dev”,
“monitoring”: “yes”,
“vpc_subnet_id”: “subnet-376d296e”
}
},
Any ideas how to delete instance? Specifically by Name (tag), we create instance in one play and want to remove them in another play.
Thanks!
erik