summaryrefslogtreecommitdiffstats
path: root/ansible
diff options
context:
space:
mode:
authorPavel Raiskup <praiskup@redhat.com>2014-10-20 15:03:26 +0200
committerPavel Raiskup <praiskup@redhat.com>2014-10-20 15:30:45 +0200
commitfa94bd10b74748c87272edbc7d93abc335949e94 (patch)
treefe4a6649a14314e806725b4d0079e5279d014bf8 /ansible
parent42ab13ada931882e9aab25085aed98bb76f970e6 (diff)
downloadpostgresql-setup-tests-fa94bd10b74748c87272edbc7d93abc335949e94.tar.gz
postgresql-setup-tests-fa94bd10b74748c87272edbc7d93abc335949e94.tar.xz
postgresql-setup-tests-fa94bd10b74748c87272edbc7d93abc335949e94.zip
run_remote: allow installing not-yet-stable packages
For that purpose you may use '--extra-rpms-file FILE' option where the file contains list of rpms to be installed. The RPMs should be defined like accessible URLs from testing machine. Also, export the overall log file as dtf-run.overview. * run_remote: Add new option --extra-rpms-file. * ansible/fedora.yml: Include conditionally the additional-packages playbook. Generate the dtf-run.overview. * ansible/include/additional-packages.yml: New playbook used to install explicit list of additional packages. * ansible/include/download-results.yml: Fix to download also dtf-run.overview file.
Diffstat (limited to 'ansible')
-rw-r--r--ansible/fedora.yml5
-rw-r--r--ansible/include/additional-packages.yml6
-rw-r--r--ansible/include/download-results.yml2
3 files changed, 12 insertions, 1 deletions
diff --git a/ansible/fedora.yml b/ansible/fedora.yml
index d96ef90..5f9eba8 100644
--- a/ansible/fedora.yml
+++ b/ansible/fedora.yml
@@ -50,9 +50,12 @@
- include: include/prepare-testenv.yml
+ - include: include/additional-packages.yml
+ when: dtf_rpm_files_list is defined
+
- shell: cd /root && tar -xf postgresql-setup-tests.tar.gz
- - shell: cd /root/postgresql-setup-tests && ./run
+ - shell: cd /root/postgresql-setup-tests && ./run &>/var/tmp/dtf-run.overview
register: test_result
ignore_errors: yes
diff --git a/ansible/include/additional-packages.yml b/ansible/include/additional-packages.yml
new file mode 100644
index 0000000..f821255
--- /dev/null
+++ b/ansible/include/additional-packages.yml
@@ -0,0 +1,6 @@
+- local_action: shell cat "{{ dtf_rpm_files_list }}" | xargs -n 100
+ register: additional_packages
+
+- debug: msg="{{ additional_packages.stdout }}"
+
+- shell: yum install -y {{ additional_packages.stdout }}
diff --git a/ansible/include/download-results.yml b/ansible/include/download-results.yml
index e3a551d..74b35b8 100644
--- a/ansible/include/download-results.yml
+++ b/ansible/include/download-results.yml
@@ -1,3 +1,5 @@
+- shell: cp -f /var/tmp/dtf-run.overview /var/tmp/dtf/
+
- shell: cd /var/tmp ; tar -czf dtf.tar.gz dtf
- fetch: src=/var/tmp/dtf.tar.gz dest="{{ opt_tmp_resultdir }}/" flat=yes