diff --git a/inventory/host_vars/209.132.184.116 b/inventory/host_vars/209.132.184.116 new file mode 100644 index 0000000000..77c66dcb1f --- /dev/null +++ b/inventory/host_vars/209.132.184.116 @@ -0,0 +1,11 @@ +--- +instance_type: m1.small +image: emi-B8793915 +keypair: admin +security_group: webserver +zone: fedoracloud +hostbase: elections-dev- +public_ip: 209.132.184.116 +root_auth_users: toshio fchiulli +description: cloud instance for developing the next version of the elections app +volumes: ['-d /dev/vdb vol-584A3E33'] diff --git a/inventory/inventory b/inventory/inventory index 735b9e26c2..691e56aa84 100644 --- a/inventory/inventory +++ b/inventory/inventory @@ -321,6 +321,8 @@ virthost-comm01.qa.fedoraproject.org 209.132.184.114 #artboard.cloud.fedoraproject.org 209.132.184.115 +#elections-dev.cloud.fedoraproject.org +209.132.184.116 [twistedbots] #rhel6 twisted testbot - ticket 3537 diff --git a/playbooks/hosts/elections-dev.cloud.fedoraproject.org.yml b/playbooks/hosts/elections-dev.cloud.fedoraproject.org.yml new file mode 100644 index 0000000000..79831f774b --- /dev/null +++ b/playbooks/hosts/elections-dev.cloud.fedoraproject.org.yml @@ -0,0 +1,52 @@ +- name: check/create instance + hosts: 209.132.184.116 + user: root + gather_facts: False + + vars_files: + - /srv/web/infra/ansible/vars/global.yml + - ${private}/vars.yml + + tasks: + - include: $tasks/persistent_cloud.yml + +- name: provision instance + hosts: 209.132.184.116 + user: root + gather_facts: True + + vars_files: + - /srv/web/infra/ansible/vars/global.yml + - ${private}/vars.yml + - ${vars}/${ansible_distribution}.yml + + tasks: + - include: $tasks/cloud_setup_basic.yml + + # Format, then add this + #- name: mount up disk of persistent storage + # action: mount name=/srv/persist src='LABEL=elections' fstype=ext4 state=mounted + + # open up ports (22, 80, 443) + - name: poke holes in the firewall + action: command lokkit $item + with_items: + - --service=ssh + - --service=https + - --service=http + + # packages needed + - name: add packages for repo + action: yum state=present name=$item + with_items: + - rsync + - openssh-clients + - httpd + - httpd-tools + - cronie-noanacron + + - name: startup apache + action: service name=httpd state=started + + handlers: + - include: $handlers/restart_services.yml