Use Python 2 on CentOS 7
Python 3, CentOS 7 and SELinux do not mix well. Change-Id: I8a179aad45b89d7eee0716abd5e7428dc51e8b11
This commit is contained in:
parent
91a4508115
commit
29ce8dd0bd
playbooks/tenks-deploy-teardown
@ -23,12 +23,13 @@
|
||||
become: true
|
||||
package:
|
||||
name: python3
|
||||
when: ansible_python.version.major == 3
|
||||
|
||||
- name: Create virtualenv for tenks
|
||||
pip:
|
||||
requirements: "{{ tenks_src_dir }}/requirements.txt"
|
||||
virtualenv: "{{ tenks_venv }}"
|
||||
virtualenv_python: python3
|
||||
virtualenv_python: "{{ ansible_python.executable }}"
|
||||
|
||||
- name: Template requirements overrides
|
||||
template:
|
||||
|
@ -1,6 +1,6 @@
|
||||
---
|
||||
# Use python3 on Ubuntu remote hosts.
|
||||
ansible_python_interpreter: "{{ '/usr/bin/python3' if ansible_os_family != 'RedHat' else '/usr/bin/python2' }}"
|
||||
ansible_python_interpreter: "{{ '/usr/bin/python3' if ansible_python.version.major == 3 else '/usr/bin/python2' }}"
|
||||
|
||||
# This file holds the config given to Tenks when running the zuul job,
|
||||
# tenks-deploy-teardown. It assumes the existence of the bridge `breth1`.
|
||||
|
Loading…
x
Reference in New Issue
Block a user