blob: cc56304346c55bde95a5116e33e436681c89b0cf [file] [log] [blame]
Matteo Scandolo55bb0962017-12-20 16:06:19 -08001---
Matteo Scandolo3896c472017-08-01 13:31:42 -07002# Copyright 2017-present Open Networking Foundation
3#
4# Licensed under the Apache License, Version 2.0 (the "License");
5# you may not use this file except in compliance with the License.
6# You may obtain a copy of the License at
7#
8# http://www.apache.org/licenses/LICENSE-2.0
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS,
12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13# See the License for the specific language governing permissions and
14# limitations under the License.
15
Zack Williamsa2763112017-01-03 11:38:38 -070016# xos-config/tasks/main.yml
Scott Bakere0a80892016-11-23 12:07:07 -080017
Matteo Scandolo55bb0962017-12-20 16:06:19 -080018- name: Bootstrap XOS database - create site, deployment, admin user
19 uri:
20 url: "{{ xos_tosca_url }}/run"
21 method: POST
22 headers:
23 xos-username: "{{ xos_admin_user }}"
24 xos-password: "{{ head_xos_admin_pass }}"
25 body: "{{ lookup('file', head_cord_profile_dir + '/' + item ) }}"
26 status_code: 200
27 register: result
28 until: result | success
29 retries: 40
30 delay: 2
31 with_items:
32 - "fixtures.yaml"
33 - "deployment.yaml"
Matteo Scandolob92469d2017-07-28 17:32:00 -070034
Matteo Scandolo55bb0962017-12-20 16:06:19 -080035- name: Configure XOS with OpenStack config
36 uri:
37 url: "{{ xos_tosca_url }}/run"
38 method: POST
39 headers:
40 xos-username: "{{ xos_admin_user }}"
41 xos-password: "{{ head_xos_admin_pass }}"
42 body: "{{ lookup('file', head_cord_profile_dir + '/' + item ) }}"
43 status_code: 200
44 register: result
45 until: result | success
46 retries: 40
47 delay: 2
48 with_items:
49 - openstack.yaml
Andy Bavier9e7d54a2017-04-17 11:37:02 -040050
Matteo Scandolo55bb0962017-12-20 16:06:19 -080051- name: Configure XOS with profile specific TOSCA (new Engine)
52 uri:
53 url: "{{ xos_tosca_url }}/run"
54 method: POST
55 headers:
56 xos-username: "{{ xos_admin_user }}"
57 xos-password: "{{ head_xos_admin_pass }}"
58 body: "{{ lookup('file', head_cord_profile_dir + '/' + item ) }}"
59 status_code: 200
60 register: result
61 until: result | success
62 retries: 40
63 delay: 2
64 with_items: "{{ xos_new_tosca_config_templates }}"