Skip to content

Commit

Permalink
sit.glusterfs/setup: Install latest available ansible version
Browse files Browse the repository at this point in the history
Now that the required fixes[1] are in for gluster-ansible we could use
latest ansible packages. In addition to that we split the installation
of python jmespath module to be more correct depending on the distro
version.

[1] gluster/gluster-ansible-infra#136

Signed-off-by: Anoop C S <anoopcs@cryptolab.net>
  • Loading branch information
anoopcs9 committed Oct 13, 2023
1 parent 1d0e622 commit 897b7ed
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 19 deletions.
28 changes: 9 additions & 19 deletions vagrant/roles/sit.glusterfs/tasks/setup/centos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,29 +5,19 @@
- name: Install gluster-ansible
yum:
name:
# Restricting to Ansible v2.12.x
# See https://github.com/gluster/gluster-ansible-infra/issues/135
- ansible-core-2.12*
- ansible-core
- gluster-ansible-cluster
- gluster-ansible-features
- gluster-ansible-infra
- gluster-ansible-maintenance
- gluster-ansible-repositories
state: latest

- name: Install required ansible collections and dependencies
block:
- name: Install ansible collections
become: no
shell: ansible-galaxy collection install --no-cache {{ item }}
loop:
- ansible.posix
- community.general
- gluster.gluster
- ovirt.ovirt

- name: Install ansible collection dependencies
pip:
name: jmespath
executable: pip3.8
state: latest
- name: Install required ansible collections
become: no
shell: ansible-galaxy collection install {{ item }}
loop:
- ansible.posix
- community.general
- gluster.gluster
- ovirt.ovirt
9 changes: 9 additions & 0 deletions vagrant/roles/sit.glusterfs/tasks/setup/centos8.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
- name: Process common OS tasks
include_tasks: centos.yml

- name: Install Python jmespath module
yum:
name:
- python3.11-jmespath
state: latest
9 changes: 9 additions & 0 deletions vagrant/roles/sit.glusterfs/tasks/setup/centos9.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
- name: Process common OS tasks
include_tasks: centos.yml

- name: Install Python jmespath module
yum:
name:
- python3-jmespath
state: latest

0 comments on commit 897b7ed

Please sign in to comment.