From ccc2a371eef3c3309f236e43fe4cbc72dd6865b2 Mon Sep 17 00:00:00 2001 From: Lorin Hochstein Date: Sun, 8 Feb 2015 22:49:25 -0500 Subject: [PATCH] Add packer --- ch12/packer/web-ami.yml | 6 ++++++ ch12/packer/web.json | 10 +++++----- 2 files changed, 11 insertions(+), 5 deletions(-) create mode 100644 ch12/packer/web-ami.yml diff --git a/ch12/packer/web-ami.yml b/ch12/packer/web-ami.yml new file mode 100644 index 0000000..1136c86 --- /dev/null +++ b/ch12/packer/web-ami.yml @@ -0,0 +1,6 @@ +--- +- name: configure a webserver as an ami + hosts: localhost + sudo: True + roles: + - web diff --git a/ch12/packer/web.json b/ch12/packer/web.json index 435b589..41f08ab 100644 --- a/ch12/packer/web.json +++ b/ch12/packer/web.json @@ -2,9 +2,9 @@ "builders": [ { "type": "amazon-ebs", - "region": "us-east-1", - "source_ami": "ami-8caa1ce4", - "instance_type": "t1.micro", + "region": "us-west-1", + "source_ami": "ami-50120b15", + "instance_type": "t2.micro", "ssh_username": "ubuntu", "ami_name": "web-nginx-{{timestamp}}", "tags": { @@ -25,8 +25,8 @@ "type": "ansible-local", "playbook_file": "web-ami.yml", "role_paths": [ - "/Users/lorinhochstein/dev/oreilly-ansible/playbooks/roles/web" + "/Users/lorinhochstein/dev/ansiblebook/ch12/playbooks/roles/web" ] } ] -} \ No newline at end of file +} -- 2.44.0