提交 6dc64dc3 编写于 作者: C Cleber Rosa

Deployment check: add Python 2 packages

This includes Python packages and a a virtualenv script for systems
that lack them.
Signed-off-by: NCleber Rosa <crosa@redhat.com>
上级 e4181cca
......@@ -14,6 +14,7 @@
- include_vars: vars.yml
- include_tasks: tasks/epel.yml
- include_tasks: tasks/python_rpm_pkgs.yml
- include_tasks: tasks/virtualenv_script.yml
- name: Temporary dir for Avocado venv
tempfile:
state: directory
......
......@@ -5,3 +5,14 @@
state: latest
with_items: "{{ avocado_python_rpm_packages }}"
when: ansible_facts['distribution_file_variety'] == "RedHat"
- name: Install Python 2 Depedencies on Fedora 29 and later systems
package:
name: "{{ item }}"
state: latest
with_items:
- python2-pip
- python2-virtualenv
- python2-libselinux
when:
- ansible_facts['distribution'] == "Fedora"
- ansible_facts['distribution_major_version'] == "29"
---
- name: Virtualenv script for systems without one
copy:
content: "#!/usr/bin/python\nimport virtualenv\nvirtualenv.main()"
dest: /usr/local/bin/virtualenv
mode: 0775
when:
- ansible_facts['distribution'] == "Fedora"
- ansible_facts['distribution_major_version'] == "29"
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册