From eef2b135507707209bed1b021d1f346e99ca39ab Mon Sep 17 00:00:00 2001 From: Lorin Hochstein Date: Sun, 12 Feb 2017 13:36:58 -0800 Subject: [PATCH] Add a simple script for starting an instance --- ch12/playbooks/start-instance.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 ch12/playbooks/start-instance.yml diff --git a/ch12/playbooks/start-instance.yml b/ch12/playbooks/start-instance.yml new file mode 100644 index 0000000..2f0d345 --- /dev/null +++ b/ch12/playbooks/start-instance.yml @@ -0,0 +1,16 @@ +- name: start an instance with the packered ami + hosts: localhost + gather_facts: False + tasks: + - name: start the instance + ec2: + region: us-west-1 + image: ami-42ffa322 + instance_type: t2.micro + key_name: mykey + group: [web, ssh, outbound] + instance_tags: + Name: packer test + register: result + - debug: var=result + -- 2.44.0