blob: 330d51263ffdb9bab9063b399a421e5870b412fe [file] [log] [blame]
Sergio Slobodrianee4b2bc2017-06-05 10:08:59 -04001- name: Ansible repository is available
2 apt_repository:
3 repo: 'ppa:ansible/ansible'
4 tags: [installer]
5- name: Debian ansible is present
6 apt:
7 name: ansible
8 state: latest
9 force: yes
10 tags: [installer]
11- name: Installer files and directories are copied
12 copy:
13 src: "{{ cord_home }}/incubator/voltha/{{ item }}"
14 dest: /home/vinstall
15 owner: vinstall
16 group: vinstall
17 with_items:
18 - install/installer.sh
19 - install/install.cfg
20 - install/ansible
21 - compose
22 - nginx_config
23 tags: [installer]
24- name: Determine if test mode is active
Sergio Slobodrianc5477712017-06-07 11:56:56 -040025 become: false
Sergio Slobodrianee4b2bc2017-06-05 10:08:59 -040026 local_action: stat path="{{ cord_home }}/incubator/voltha/install/.test"
27 register: file
Sergio Slobodrianc5477712017-06-07 11:56:56 -040028 ignore_errors: true
Sergio Slobodrianee4b2bc2017-06-05 10:08:59 -040029- name: Test mode file is copied
30 copy:
31 src: "{{ cord_home }}/incubator/voltha/install/.test"
32 dest: /home/vinstall
33 when: file.stat.exists
34- name: The installer is made executable
35 file:
36 path: /home/vinstall/installer.sh
37 mode: 0744
38 tags: [installer]
39- name: Python docker-py 1.6.0 package source is available
40 command: pip download -d /home/vinstall/docker-py "docker-py==1.6.0"
41 tags: [installer]
42- name: Python netifaces 0.10.4 package source is available
43 command: pip download -d /home/vinstall/netifaces "netifaces==0.10.4"
44 tags: [installer]
Sergio Slobodrianc5477712017-06-07 11:56:56 -040045- name: Deb file directory doesn't exist
46 file:
47 path: /home/vinstall/deb_files
48 state: absent
49 tags: [installer]
Sergio Slobodrianee4b2bc2017-06-05 10:08:59 -040050- name: Deb files are saved.
51 command: cp -r /var/cache/apt/archives /home/vinstall
52 tags: [installer]
53- name: Deb file directory is renamed
54 command: mv /home/vinstall/archives /home/vinstall/deb_files
55 tags: [installer]