summaryrefslogtreecommitdiffstats
path: root/ci/nbp-ansible/roles/common/tasks/main.yml
blob: b612e2453729da3bd0c69ead0a916cfed6eb8853 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
---
- name: Run the equivalent of "apt-get update" as a separate step
  apt:
    update_cache: yes

- name: check for nbp release files existed
  stat:
    path: "{{ nbp_dir }}"
  ignore_errors: yes
  register: releasesexisted

- name: download nbp release files
  get_url:
    url={{ nbp_download_url }}
    dest={{ nbp_tarball_url }}
  when:
    - releasesexisted.stat.exists is undefined or releasesexisted.stat.exists == false

- name: extract the nbp release tarball
  unarchive:
    src={{ nbp_tarball_url }}
    dest=/opt/
  when:
    - releasesexisted.stat.exists is undefined or releasesexisted.stat.exists == false