From 96fa64e8f28b1b7fe3eec62e37cfcd42a342bfef Mon Sep 17 00:00:00 2001 From: Seth Vidal Date: Fri, 26 Apr 2013 21:48:18 +0000 Subject: [PATCH] an f19 playbook - and qcow_id for it --- playbooks/f19-temp-instance.yml | 44 +++++++++++++++++++++++++++++++++ vars/global.yml | 1 + 2 files changed, 45 insertions(+) create mode 100644 playbooks/f19-temp-instance.yml diff --git a/playbooks/f19-temp-instance.yml b/playbooks/f19-temp-instance.yml new file mode 100644 index 0000000000..1dd7ba970e --- /dev/null +++ b/playbooks/f19-temp-instance.yml @@ -0,0 +1,44 @@ +# setup a transient fedora instance +# optionally can take --extra-vars="hostbase=hostnamebase root_auth_users='user1 user2 user3'" + +- name: check/create instance + hosts: lockbox01.phx2.fedoraproject.org + user: root + gather_facts: False + + vars_files: + - /srv/web/infra/ansible/vars/global.yml + - ${private}/vars.yml + vars: + - keypair: fedora-admin + - image: $f19_qcow_id + - instance_type: m1.small + - security_group: default + + tasks: + - include: $tasks/transient_cloud.yml + +- name: provision instance + hosts: tmp_just_created + user: root + gather_facts: True + + vars_files: + - /srv/web/infra/ansible/vars/global.yml + - ${private}/vars.yml + - ${vars}/${ansible_distribution}.yml + + tasks: + - name: growpart the second partition (/) to full size + action: command growpart /dev/vda 1 + ignore_errors: true + register: growpart + + - name: resize the /dev/vda 1 fs + action: command resize2fs /dev/vda1 + when_integer: ${growpart.rc} == 0 + + - include: $tasks/cloud_setup_basic.yml + + handlers: + - include: $handlers/restart_services.yml diff --git a/vars/global.yml b/vars/global.yml index 09685732b8..f0df4b195a 100644 --- a/vars/global.yml +++ b/vars/global.yml @@ -13,3 +13,4 @@ el6_qcow_id: ami-00000013 f18_qcow_id: ami-00000016 el6_ami_id: ami-0000000e f17_qcow_id: ami-00000001 +f19_qcow_id: ami-00000018