From b10164589d797445ba501f86a107ce9f009f40b1 Mon Sep 17 00:00:00 2001 From: Werner Dijkerman Date: Thu, 6 Feb 2025 20:13:24 +0100 Subject: [PATCH 1/7] Upgrading as older version for pipeline job doesn't seem to work anymore --- .github/workflows/telegraf.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/telegraf.yml b/.github/workflows/telegraf.yml index 1c47be2..375913f 100644 --- a/.github/workflows/telegraf.yml +++ b/.github/workflows/telegraf.yml @@ -48,7 +48,7 @@ jobs: - name: Set up Python 3.11 uses: actions/setup-python@v1 with: - python-version: 3.11.10 + python-version: 3.11.11 - name: Install dependencies run: | From 6552bb02fc4a04a15ec8a464aab85cb5fa2ad751 Mon Sep 17 00:00:00 2001 From: Werner Dijkerman Date: Thu, 6 Feb 2025 20:14:48 +0100 Subject: [PATCH 2/7] Updating dependency versions for ci job as well --- requirements.txt | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/requirements.txt b/requirements.txt index b029d34..44f4568 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,11 +1,11 @@ -ansible==9.7.0 -ansible-compat==24.10.0 -ansible-core==2.18.1 +ansible==11.2.0 +ansible-compat==25.1.2 +ansible-core==2.18.2 docker==7.1.0 -molecule==6.0.3 +molecule==25.2.0 molecule-docker==2.1.0 -molecule-plugins==23.5.3 +molecule-plugins==23.7.0 netaddr==1.3.0 -pytest==8.3.3 +pytest==8.3.4 pytest-testinfra==10.1.1 testinfra==6.0.0 From dc3825add5861b86fbd646d2d5a0c64a3afe48e4 Mon Sep 17 00:00:00 2001 From: Werner Dijkerman Date: Fri, 7 Feb 2025 17:05:36 +0100 Subject: [PATCH 3/7] Using envs properly --- .github/workflows/telegraf.yml | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/.github/workflows/telegraf.yml b/.github/workflows/telegraf.yml index 375913f..de0cd54 100644 --- a/.github/workflows/telegraf.yml +++ b/.github/workflows/telegraf.yml @@ -43,10 +43,10 @@ jobs: image: geerlingguy/docker-debian11-ansible:latest steps: - name: Check out code - uses: actions/checkout@v1 + uses: actions/checkout@v4 - name: Set up Python 3.11 - uses: actions/setup-python@v1 + uses: actions/setup-python@v5 with: python-version: 3.11.11 @@ -56,17 +56,17 @@ jobs: pip install -r requirements.txt - name: Run role tests on empty systems in check-mode - run: >- - MY_MOLECULE_CONTAINER=${{ matrix.molecule_distro.container }} - MY_MOLECULE_IMAGE=${{ matrix.molecule_distro.image }} - MY_MOLECULE_GROUP=${{ matrix.molecule_distro.group }} - MY_MOLECULE_DOCKER_COMMAND=${{ matrix.molecule_distro.command }} - molecule test -s empty-checkmode + env: + MY_MOLECULE_CONTAINER: ${{ matrix.molecule_distro.container }} + MY_MOLECULE_IMAGE: ${{ matrix.molecule_distro.image }} + MY_MOLECULE_GROUP: ${{ matrix.molecule_distro.group }} + MY_MOLECULE_DOCKER_COMMAND: ${{ matrix.molecule_distro.command }} + run: molecule test -s empty-checkmode - name: Run role tests - run: >- - MY_MOLECULE_CONTAINER=${{ matrix.molecule_distro.container }} - MY_MOLECULE_IMAGE=${{ matrix.molecule_distro.image }} - MY_MOLECULE_GROUP=${{ matrix.molecule_distro.group }} - MY_MOLECULE_DOCKER_COMMAND=${{ matrix.molecule_distro.command }} - molecule test + env: + MY_MOLECULE_CONTAINER: ${{ matrix.molecule_distro.container }} + MY_MOLECULE_IMAGE: ${{ matrix.molecule_distro.image }} + MY_MOLECULE_GROUP: ${{ matrix.molecule_distro.group }} + MY_MOLECULE_DOCKER_COMMAND: ${{ matrix.molecule_distro.command }} + run: molecule test From 1f142bd1a557c9d6fac7ca0e2941df0133d36a6a Mon Sep 17 00:00:00 2001 From: Werner Dijkerman Date: Fri, 7 Feb 2025 17:18:41 +0100 Subject: [PATCH 4/7] Attempt to make it work --- molecule/default/converge.yml | 2 +- molecule/empty-checkmode/converge.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/molecule/default/converge.yml b/molecule/default/converge.yml index f911bae..575e181 100644 --- a/molecule/default/converge.yml +++ b/molecule/default/converge.yml @@ -1,4 +1,4 @@ --- - hosts: telegraf roles: - - role: ansible-telegraf + - role: ../../ansible-telegraf diff --git a/molecule/empty-checkmode/converge.yml b/molecule/empty-checkmode/converge.yml index f911bae..575e181 100644 --- a/molecule/empty-checkmode/converge.yml +++ b/molecule/empty-checkmode/converge.yml @@ -1,4 +1,4 @@ --- - hosts: telegraf roles: - - role: ansible-telegraf + - role: ../../ansible-telegraf From 2088fc7001f937d243656b20051d3d3a2f8af109 Mon Sep 17 00:00:00 2001 From: Werner Dijkerman Date: Fri, 7 Feb 2025 17:24:27 +0100 Subject: [PATCH 5/7] Another Attempt to make it work --- molecule/empty-checkmode/converge.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/molecule/empty-checkmode/converge.yml b/molecule/empty-checkmode/converge.yml index 575e181..2f6e326 100644 --- a/molecule/empty-checkmode/converge.yml +++ b/molecule/empty-checkmode/converge.yml @@ -1,4 +1,4 @@ --- - hosts: telegraf roles: - - role: ../../ansible-telegraf + - role: ../../../ansible-telegraf From 1c6c4b02fba267dbc5fc4a3281c715146ff6edda Mon Sep 17 00:00:00 2001 From: Werner Dijkerman Date: Fri, 7 Feb 2025 17:33:28 +0100 Subject: [PATCH 6/7] Another attempt to make it work --- .github/workflows/telegraf.yml | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/.github/workflows/telegraf.yml b/.github/workflows/telegraf.yml index de0cd54..79b3eaa 100644 --- a/.github/workflows/telegraf.yml +++ b/.github/workflows/telegraf.yml @@ -50,10 +50,13 @@ jobs: with: python-version: 3.11.11 - - name: Install dependencies - run: | - python -m pip install --upgrade pip - pip install -r requirements.txt + # - name: Install dependencies + # run: | + # python -m pip install --upgrade pip + # pip install -r requirements.txt + + - name: Install test dependencies. + run: pip3 install ansible molecule molecule-plugins[docker] docker - name: Run role tests on empty systems in check-mode env: From 084df32f10208940f84f31669f3c0979b9d5f61c Mon Sep 17 00:00:00 2001 From: Werner Dijkerman Date: Fri, 7 Feb 2025 17:40:26 +0100 Subject: [PATCH 7/7] Another attempt to make it work (2) --- .github/workflows/telegraf.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/telegraf.yml b/.github/workflows/telegraf.yml index 79b3eaa..8859023 100644 --- a/.github/workflows/telegraf.yml +++ b/.github/workflows/telegraf.yml @@ -27,16 +27,16 @@ jobs: fail-fast: false matrix: molecule_distro: - - container: rocky8 - image: geerlingguy/docker-rockylinux8-ansible + # - container: rocky8 + # image: geerlingguy/docker-rockylinux8-ansible - container: rocky9 image: geerlingguy/docker-rockylinux9-ansible - container: ubuntu2204 image: geerlingguy/docker-ubuntu2204-ansible:latest - container: ubuntu2004 image: geerlingguy/docker-ubuntu2004-ansible:latest - - container: ubuntu1804 - image: geerlingguy/docker-ubuntu1804-ansible:latest + # - container: ubuntu1804 + # image: geerlingguy/docker-ubuntu1804-ansible:latest - container: debian10 image: geerlingguy/docker-debian10-ansible:latest - container: debian11 @@ -56,7 +56,7 @@ jobs: # pip install -r requirements.txt - name: Install test dependencies. - run: pip3 install ansible molecule molecule-plugins[docker] docker + run: pip3 install ansible molecule molecule-plugins[docker] docker pytest testinfra - name: Run role tests on empty systems in check-mode env: