Matteo Scandolo | 3896c47 | 2017-08-01 13:31:42 -0700 | [diff] [blame] | 1 | |
| 2 | # 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 | |
| 16 | |
Scott Baker | 58e88a8 | 2016-11-18 13:39:09 -0800 | [diff] [blame] | 17 | --- |
Zack Williams | c989f26 | 2017-05-11 13:02:59 -0700 | [diff] [blame] | 18 | # onos-fabric-install/tasks/main.yml |
Scott Baker | 58e88a8 | 2016-11-18 13:39:09 -0800 | [diff] [blame] | 19 | |
Zack Williams | c989f26 | 2017-05-11 13:02:59 -0700 | [diff] [blame] | 20 | - name: Pull base docker image for ONOS |
| 21 | docker_image: |
| 22 | name: "{{ onos_docker_image }}" |
| 23 | |
| 24 | - name: Create onos-fabric dest directory |
Scott Baker | 58e88a8 | 2016-11-18 13:39:09 -0800 | [diff] [blame] | 25 | become: yes |
Jonathan Hart | 2a3c01e | 2017-01-13 17:32:27 -0800 | [diff] [blame] | 26 | file: |
Zack Williams | c989f26 | 2017-05-11 13:02:59 -0700 | [diff] [blame] | 27 | path: "{{ head_onos_fabric_dir }}" |
Jonathan Hart | 2a3c01e | 2017-01-13 17:32:27 -0800 | [diff] [blame] | 28 | state: directory |
Zack Williams | c989f26 | 2017-05-11 13:02:59 -0700 | [diff] [blame] | 29 | owner: "{{ ansible_user_id }}" |
| 30 | group: "{{ ansible_user_gid }}" |
| 31 | mode: 0755 |
Scott Baker | 58e88a8 | 2016-11-18 13:39:09 -0800 | [diff] [blame] | 32 | |
| 33 | - name: Create templated ONOS files |
| 34 | template: |
| 35 | src: "{{ item }}.j2" |
Zack Williams | c989f26 | 2017-05-11 13:02:59 -0700 | [diff] [blame] | 36 | dest: "{{ head_onos_fabric_dir }}/{{ item }}" |
Scott Baker | 58e88a8 | 2016-11-18 13:39:09 -0800 | [diff] [blame] | 37 | with_items: |
Jonathan Hart | 2a3c01e | 2017-01-13 17:32:27 -0800 | [diff] [blame] | 38 | - docker-compose.yml |
Scott Baker | 58e88a8 | 2016-11-18 13:39:09 -0800 | [diff] [blame] | 39 | |
| 40 | # Note: we do not rebuild onos container for the fabric |
| 41 | |
Zack Williams | c989f26 | 2017-05-11 13:02:59 -0700 | [diff] [blame] | 42 | - name: Start ONOS for fabric |
| 43 | docker_service: |
Zack Williams | a88041c | 2017-09-13 10:11:55 -0700 | [diff] [blame] | 44 | project_name: "onosfabric" |
Zack Williams | c989f26 | 2017-05-11 13:02:59 -0700 | [diff] [blame] | 45 | project_src: "{{ head_onos_fabric_dir }}" |
Scott Baker | 58e88a8 | 2016-11-18 13:39:09 -0800 | [diff] [blame] | 46 | |