From f900bb250ec5266fb119ad845588b4dc05e296f2 Mon Sep 17 00:00:00 2001 From: "guillaume.lambert" Date: Wed, 30 Aug 2023 11:37:29 +0200 Subject: [PATCH] Improve Xtesting installation procedure - use a requirements.yml file to install ansible roles and collections https://github.com/collivier/ansible-role-xtesting/pull/19 has been fixed in the master branch cf commit 1a5794a34beada2a2e69b9d46f933f2a286774e9 - remove related workaround notes from INSTALL.txt - force to use collivier.xtesting master branch repo in requirements.yml until the fix is published in ansible official catalog Change-Id: Ia4e33d5ea327bffef7ed214907823e2ee77e87b7 --- tests/Xtesting/INSTALL.txt | 6 +----- tests/Xtesting/requirements.yml | 16 ++++++++++++++++ 2 files changed, 17 insertions(+), 5 deletions(-) create mode 100644 tests/Xtesting/requirements.yml diff --git a/tests/Xtesting/INSTALL.txt b/tests/Xtesting/INSTALL.txt index eb47e85e3..2ee3a5eac 100644 --- a/tests/Xtesting/INSTALL.txt +++ b/tests/Xtesting/INSTALL.txt @@ -9,11 +9,7 @@ sudo apt-get install virtualenv virtualenv xtesting -p python3 --system-site-packages . xtesting/bin/activate pip install ansible -ansible-galaxy install collivier.xtesting -## Until https://github.com/collivier/ansible-role-xtesting/pull/19 is fixed, the following command -## or any equivalent must be performed so that the playbook correctly performs Jenkins configuration -## sed -i_ 's/port\:{/port: {/' ~/.ansible/roles/collivier.xtesting/templates/run.yaml.j2 -ansible-galaxy collection install ansible.posix community.general community.grafana community.kubernetes community.docker community.postgresql +ansible-galaxy install -r requirements.yml ansible-playbook site.yml deactivate sudo docker build -t 127.0.0.1:5000/tpce0 . diff --git a/tests/Xtesting/requirements.yml b/tests/Xtesting/requirements.yml new file mode 100644 index 000000000..a54612698 --- /dev/null +++ b/tests/Xtesting/requirements.yml @@ -0,0 +1,16 @@ +--- +roles: + - name: collivier.xtesting + src: https://github.com/collivier/ansible-role-xtesting + version: master + # to use xtesting GitHub repo master branch until a version > 4.2.0 + # is published in ansible catalog to bring the following fix + # https://github.com/collivier/ansible-role-xtesting/pull/19 + +collections: + - name: ansible.posix + - name: community.general + - name: community.grafana + - name: community.kubernetes + - name: community.docker + - name: community.postgresql -- 2.36.6