Merge "PROX: [WIP] Added scale up TCs."
[yardstick.git] / ansible / roles / infra_deploy_openstack / tasks / install_kolla.yml
1 # Copyright (c) 2018 Intel Corporation.
2 #
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
6 #
7 #      http://www.apache.org/licenses/LICENSE-2.0
8 #
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
14 ---
15 - name: Download kolla and kolla-ansible from git repos
16   git:
17     repo: "{{ item.repo }}"
18     dest: "{{ git_repos_path + item.dir }}"
19     version: stable/pike
20   with_items:
21     - { dir: "{{ kolla_path }}", repo: 'https://git.openstack.org/openstack/kolla'}
22     - { dir: "{{ kolla_ans_path }}", repo: 'https://git.openstack.org/openstack/kolla-ansible' }
23
24 - name: Copy kolla-ansible password.yml and globals.yml
25   shell: cp -r "{{ git_repos_path + kolla_ans_path + '/etc/kolla/' }}" /etc/
26
27 - name: Copy kolla-ansible all-in-one, multinode
28   shell: cp * "{{ git_repos_path }}"
29   args:
30     chdir: "{{ git_repos_path + kolla_ans_path + '/ansible/inventory/' }}"
31
32 - name: Install requirements
33   pip:
34     chdir: "{{ item[0] }}"
35     requirements: "{{ item[1] }}"
36   with_nested:
37     - [ "{{ git_repos_path + kolla_path }}", "{{ git_repos_path + kolla_ans_path }}" ]
38     - [ 'requirements.txt', 'test-requirements.txt' ]
39
40 - name: pip install .
41   pip:
42     chdir: "{{ item }}"
43     name: '.'
44   with_items:
45     - "{{ git_repos_path + kolla_path }}"
46     -  "{{ git_repos_path + kolla_ans_path }}"
47
48 - name: Run setup.py
49   shell: "python setup.py install"
50   args:
51     chdir: "{{ item }}"
52   with_items:
53     - "{{ git_repos_path + kolla_path }}"
54     -  "{{ git_repos_path + kolla_ans_path }}"