Merge "Fix installation of py27 on CentOS 7/8"

This commit is contained in:
Zuul 2023-05-02 04:50:22 +00:00 committed by Gerrit Code Review
commit 0e9aa6c808
1 changed files with 15 additions and 0 deletions

View File

@ -17,3 +17,18 @@
- python
- python-dev
state: present
when: ansible_facts['distribution'] != "CentOS"
- name: Install Python 2.7 for CentOS 7
package:
name:
- python
- python-devel
state: present
when: (ansible_facts['distribution'] == "CentOS" and ansible_facts['distribution_major_version'] == "7")
- name: Install Python 2.7 for CentOS 8
package:
name:
- python2
- python2-devel
state: present
when: (ansible_facts['distribution'] == "CentOS" and ansible_facts['distribution_major_version'] == "8")