diff options
Diffstat (limited to 'resources/ansible_roles/qtip-generator/files/doctor/setup.yml')
-rw-r--r-- | resources/ansible_roles/qtip-generator/files/doctor/setup.yml | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/resources/ansible_roles/qtip-generator/files/doctor/setup.yml b/resources/ansible_roles/qtip-generator/files/doctor/setup.yml new file mode 100644 index 00000000..2a1f868d --- /dev/null +++ b/resources/ansible_roles/qtip-generator/files/doctor/setup.yml @@ -0,0 +1,56 @@ +{% raw %} +############################################################################## +# Copyright (c) 2017 ZTE Corporation and others. +# +# All rights reserved. This program and the accompanying materials +# are made available under the terms of the Apache License, Version 2.0 +# which accompanies this distribution, and is available at +# http://www.apache.org/licenses/LICENSE-2.0 +############################################################################## + +--- +- hosts: doctor-tester + + gather_facts: no + + tasks: + + - name: creating doctor project + os_project: + name: "{{ doctor_project }}" + description: test project for doctor verification + domain: "{{ doctor_domain }}" + enabled: true + + - name: creating doctor user + os_user: + name: "{{ doctor_user }}" + password: "{{ doctor_pass }}" + domain: "{{ doctor_domain }}" + default_project: "{{ doctor_project }}" + + - name: assigning role to doctor user + os_user_role: + user: "{{ doctor_user }}" + role: "{{ doctor_role }}" + project: "{{ doctor_project }}" + + - name: adding admin user to doctor project + os_user_role: + user: admin + role: admin + project: "{{ doctor_project }}" + + - name: creating doctor network + os_network: + auth: "{{ doctor_auth }}" + name: "{{ doctor_network }}" + + - name: creating doctor subnet + os_subnet: + auth: "{{ doctor_auth }}" + name: "{{ doctor_subnet }}" + cidr: "{{ doctor_cidr }}" + network_name: "{{ doctor_network }}" + enable_dhcp: false +{% endraw %}
\ No newline at end of file |