ansible: Add lttng-analyses role
authorMichael Jeanson <mjeanson@efficios.com>
Tue, 26 Jul 2016 20:26:59 +0000 (16:26 -0400)
committerMichael Jeanson <mjeanson@efficios.com>
Tue, 26 Jul 2016 20:26:59 +0000 (16:26 -0400)
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
12 files changed:
automation/ansible/lava-all.yml
automation/ansible/roles/lttng-analyses/tasks/main.yml [new file with mode: 0644]
automation/ansible/roles/lttng-analyses/tasks/setup-Alpine.yml [new file with mode: 0644]
automation/ansible/roles/lttng-analyses/tasks/setup-Debian.yml [new file with mode: 0644]
automation/ansible/roles/lttng-analyses/tasks/setup-RedHat.yml [new file with mode: 0644]
automation/ansible/roles/lttng-analyses/vars/Alpine.yml [new file with mode: 0644]
automation/ansible/roles/lttng-analyses/vars/Debian.yml [new file with mode: 0644]
automation/ansible/roles/lttng-analyses/vars/RedHat.yml [new file with mode: 0644]
automation/ansible/slave-all.yml
automation/ansible/slave-amd64.yml
automation/ansible/slave-i386.yml
automation/ansible/slave-standalone.yml

index eef624846e3bb454a2c9936fae962f395952bf28..a523d1f480b6771c8429aa6467b083d8a612968c 100644 (file)
@@ -6,3 +6,4 @@
     - lttng-ust
     - lttng-tools
     - lttng-modules
+    - lttng-analyses
diff --git a/automation/ansible/roles/lttng-analyses/tasks/main.yml b/automation/ansible/roles/lttng-analyses/tasks/main.yml
new file mode 100644 (file)
index 0000000..7cb5867
--- /dev/null
@@ -0,0 +1,19 @@
+---
+# Include variables and define needed variables.
+- name: Include OS-specific variables.
+  include_vars: "{{ ansible_os_family }}.yml"
+
+- name: Define lttng_analyses_packages.
+  set_fact:
+    lttng_analyses_packages: "{{ __lttng_analyses_packages | list }}"
+  when: lttng_analyses_packages is not defined
+
+# Setup/install tasks.
+- include: setup-RedHat.yml
+  when: ansible_os_family == 'RedHat'
+
+- include: setup-Debian.yml
+  when: ansible_os_family == 'Debian'
+
+- include: setup-Alpine.yml
+  when: ansible_os_family == 'Alpine'
diff --git a/automation/ansible/roles/lttng-analyses/tasks/setup-Alpine.yml b/automation/ansible/roles/lttng-analyses/tasks/setup-Alpine.yml
new file mode 100644 (file)
index 0000000..9bb8f4a
--- /dev/null
@@ -0,0 +1,8 @@
+---
+- name: Update apk cache.
+  apk: update_cache=yes
+
+- name: Ensure lttng-analyses build dependencies are installed.
+  apk: "name={{ item }} state=present"
+  with_items: lttng_analyses_packages
+
diff --git a/automation/ansible/roles/lttng-analyses/tasks/setup-Debian.yml b/automation/ansible/roles/lttng-analyses/tasks/setup-Debian.yml
new file mode 100644 (file)
index 0000000..2c873fe
--- /dev/null
@@ -0,0 +1,8 @@
+---
+- name: Update apt cache.
+  apt: update_cache=yes cache_valid_time=86400
+
+- name: Ensure lttng-analyses build dependencies are installed.
+  apt: "name={{ item }} state=installed"
+  with_items: lttng_analyses_packages
+
diff --git a/automation/ansible/roles/lttng-analyses/tasks/setup-RedHat.yml b/automation/ansible/roles/lttng-analyses/tasks/setup-RedHat.yml
new file mode 100644 (file)
index 0000000..b350ad4
--- /dev/null
@@ -0,0 +1,6 @@
+---
+- name: Ensure lttng-analyses build dependencies are installed.
+  yum:
+    name: "{{ item }}"
+    state: installed
+  with_items: lttng_analyses_packages
diff --git a/automation/ansible/roles/lttng-analyses/vars/Alpine.yml b/automation/ansible/roles/lttng-analyses/vars/Alpine.yml
new file mode 100644 (file)
index 0000000..a882762
--- /dev/null
@@ -0,0 +1,2 @@
+---
+__lttng_analyses_packages: []
diff --git a/automation/ansible/roles/lttng-analyses/vars/Debian.yml b/automation/ansible/roles/lttng-analyses/vars/Debian.yml
new file mode 100644 (file)
index 0000000..abb147f
--- /dev/null
@@ -0,0 +1,5 @@
+---
+__lttng_analyses_packages:
+  - virtualenv
+  - python3-pyparsing
+  - python3-progressbar
diff --git a/automation/ansible/roles/lttng-analyses/vars/RedHat.yml b/automation/ansible/roles/lttng-analyses/vars/RedHat.yml
new file mode 100644 (file)
index 0000000..2b88bab
--- /dev/null
@@ -0,0 +1,2 @@
+---
+__lttng_modules_packages: []
index a66b3936a65de3e7a63dc68e3c1b75b0e39be876..c2463510965cb5cc2b35fcaa33b521da724ed7e0 100644 (file)
@@ -7,4 +7,5 @@
     - lttng-ust
     - lttng-tools
     - lttng-modules
+    - lttng-analyses
     - tracecompass
index 383570169682a8e4f8ca048d8adab1eafc94f72d..1ce4964e751d365ea72894fbf14487eb5d754673 100644 (file)
@@ -7,4 +7,5 @@
     - lttng-ust
     - lttng-tools
     - lttng-modules
+    - lttng-analyses
     - tracecompass
index 3fdebc8408a2936a000f97e102dc9c1f2091f211..460a0fb1c0d18b6bf4adccf164557c2266b94688 100644 (file)
@@ -7,4 +7,5 @@
     - lttng-ust
     - lttng-tools
     - lttng-modules
+    - lttng-analyses
     - tracecompass
index e02b42a788f495171f4145922f5c92441c1478b7..8953c3151cfb9f8f2f003d3333830ac9b70e2b52 100644 (file)
@@ -7,4 +7,5 @@
     - lttng-ust
     - lttng-tools
     - lttng-modules
+    - lttng-analyses
     - tracecompass
This page took 0.026511 seconds and 4 git commands to generate.