run-buildset-registry: Fix python version check
The "Start the buildset registry" task, which uses the docker_container Ansible module, was failing with: "No module named 'requests'" This is because the earlier package install task was installing the packages into the wrong python version because the ansible_python_interpreter value was 'auto' and thus never included the 'python3' value. Change-Id: I887fdf8d000c8b916fdab281c531b7c98bdd5ae2
This commit is contained in:
parent
d7b86832b2
commit
ce67cef122
@ -6,7 +6,7 @@
|
|||||||
- openssl
|
- openssl
|
||||||
- python-passlib
|
- python-passlib
|
||||||
state: present
|
state: present
|
||||||
when: "'python3' not in ansible_python_interpreter"
|
when: ansible_python_version is version('3', '<')
|
||||||
- name: Install packages
|
- name: Install packages
|
||||||
become: yes
|
become: yes
|
||||||
package:
|
package:
|
||||||
@ -15,7 +15,7 @@
|
|||||||
- openssl
|
- openssl
|
||||||
- python3-passlib
|
- python3-passlib
|
||||||
state: present
|
state: present
|
||||||
when: "'python3' in ansible_python_interpreter"
|
when: ansible_python_version is version('3', '>=')
|
||||||
- name: Ensure registry volume directories exists
|
- name: Ensure registry volume directories exists
|
||||||
file:
|
file:
|
||||||
state: directory
|
state: directory
|
||||||
|
Loading…
x
Reference in New Issue
Block a user