diff --git a/playbooks/temp_cloud_instance.yml b/playbooks/temp_cloud_instance.yml index fe0758b931..3e7f888a77 100644 --- a/playbooks/temp_cloud_instance.yml +++ b/playbooks/temp_cloud_instance.yml @@ -12,20 +12,8 @@ - /srv/web/infra/ansible/vars/fedora-cloud.yml - /srv/private/ansible/files/openstack/passwords.yml vars: - - keypair: fedora-admin-20130801 - - image: "{{ centos70_x86_64 }}" - - instance_type: m1.small - - security_group: web-80-anywhere-transient,web-443-anywhere-transient,ssh-anywhere-transient,default - - region: nova - - auth_url: "{{os_auth_url}}" - - login_username: "admin" - - login_password: "{{ADMIN_PASS}}" - - login_tenant_name: transient - - image_id: "{{ image|image_name_to_id('admin', ADMIN_PASS, inventory_tenant, os_auth_url) }}" - - nics: - - net-id: "28db7265-fb78-4937-bfe3-9c8a9b959c30" - - floating_ips: - - "{{public_ip}}" + image: "{{ centos70_x86_64 }}" + instance_type: m1.small tasks: - name: fail when name is not provided diff --git a/tasks/transient_cloud_new.yml b/tasks/transient_cloud_new.yml index eff67c89ce..29cc1f95a2 100644 --- a/tasks/transient_cloud_new.yml +++ b/tasks/transient_cloud_new.yml @@ -8,6 +8,14 @@ - name: spin UP VM using nova_compute sudo: False local_action: + keypair: fedora-admin-20130801 + image: "{{ image }}" + instance_type: "{{ instance_type }}" + security_group: web-80-anywhere-transient,web-443-anywhere-transient,ssh-anywhere-transient,default + region: nova + image_id: "{{ image|image_name_to_id('admin', ADMIN_PASS, inventory_tenant, os_auth_url) }}" + nics: + - net-id: "28db7265-fb78-4937-bfe3-9c8a9b959c30" name: "{{ name }}" module: nova_compute auth_url: "{{os_auth_url}}" @@ -21,6 +29,7 @@ key_name: "{{ keypair }}" floating_ips: - "{{public_ip}}" + register: nova_result when: host_is_up|failed