blob: b84fcc9659cb726c5f46088a53065402c0809348 [file] [log] [blame]
Zack Williams2f536a72017-09-19 16:37:57 -07001---
Jonathan Hart93956f52017-08-22 13:12:42 -07002
3# Copyright 2017-present Open Networking Foundation
4#
5# Licensed under the Apache License, Version 2.0 (the "License");
6# you may not use this file except in compliance with the License.
7# You may obtain a copy of the License at
8#
9# http://www.apache.org/licenses/LICENSE-2.0
10#
11# Unless required by applicable law or agreed to in writing, software
12# distributed under the License is distributed on an "AS IS" BASIS,
13# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14# See the License for the specific language governing permissions and
15# limitations under the License.
16
Zack Williams2f536a72017-09-19 16:37:57 -070017- name: "Install dependencies"
Sapan Bhatia7348d5c2017-04-16 13:07:25 -070018 become: yes
David K. Bainbridgeed101542016-05-18 20:26:15 -070019 apt:
Sapan Bhatia2adaaaf2017-04-13 19:41:53 -070020 name: "{{ item }}"
21 state: present
22 with_items:
Zack Williams2f536a72017-09-19 16:37:57 -070023 - python-netaddr
24 - python-pycurl
25 - software-properties-common
Sapan Bhatia2adaaaf2017-04-13 19:41:53 -070026 - sshpass
27
Zack Williams2f536a72017-09-19 16:37:57 -070028- name: Add ansible APT repository
Sapan Bhatia2adaaaf2017-04-13 19:41:53 -070029 become: yes
Zack Williams6fe46372017-06-29 08:30:21 -070030 apt_repository:
31 repo: "{{ ansible_apt_repo | default('ppa:ansible/ansible') }}"
32 register: result
33 until: result | success
34 retries: 3
35 delay: 10
Sapan Bhatia2adaaaf2017-04-13 19:41:53 -070036
Zack Williams2f536a72017-09-19 16:37:57 -070037- name: Make sure Ansible is latest version
Zack Williams6fe46372017-06-29 08:30:21 -070038 become: yes
39 apt:
Zack Williams2f536a72017-09-19 16:37:57 -070040 name: "ansible"
41 state: latest
42 update_cache: yes
43 cache_valid_time: 3600
44 tags:
45 - skip_ansible_lint # ansible-lint complains about latest, need this as distro provided 1.5.x version may be used if already installed.
46