Merge pull request #1377 from rjeffman/ansible_2_18

Update Ansible version in Upstream CI
This commit is contained in:
Thomas Woerner
2025-11-10 15:39:41 +01:00
committed by GitHub
5 changed files with 45 additions and 19 deletions

View File

@@ -5,7 +5,7 @@ on:
- pull_request - pull_request
jobs: jobs:
check_docs_oldest_supported: check_docs_oldest_supported:
name: Check Ansible Documentation with ansible-core 2.13. name: Check Ansible Documentation with ansible-core 2.16.
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v4.1.1 - uses: actions/checkout@v4.1.1
@@ -14,15 +14,15 @@ jobs:
- uses: actions/setup-python@v5.1.0 - uses: actions/setup-python@v5.1.0
with: with:
python-version: '3.x' python-version: '3.x'
- name: Install Ansible 2.13 - name: Install Ansible 2.16
run: | run: |
python -m pip install "ansible-core >=2.13,<2.14" python -m pip install "ansible-core >=2.16,<2.17"
- name: Run ansible-doc-test - name: Run ansible-doc-test
run: | run: |
ANSIBLE_LIBRARY="." ANSIBLE_DOC_FRAGMENT_PLUGINS="." python utils/ansible-doc-test -v roles plugins ANSIBLE_LIBRARY="." ANSIBLE_DOC_FRAGMENT_PLUGINS="." python utils/ansible-doc-test -v roles plugins
check_docs_previous: check_docs_previous:
name: Check Ansible Documentation with ansible-core 2.14. name: Check Ansible Documentation with ansible-core 2.18.
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v4.1.1 - uses: actions/checkout@v4.1.1
@@ -31,15 +31,15 @@ jobs:
- uses: actions/setup-python@v5.1.0 - uses: actions/setup-python@v5.1.0
with: with:
python-version: '3.x' python-version: '3.x'
- name: Install Ansible 2.14 - name: Install Ansible 2.18
run: | run: |
python -m pip install "ansible-core >=2.14,<2.15" python -m pip install "ansible-core >=2.18,<2.19"
- name: Run ansible-doc-test - name: Run ansible-doc-test
run: | run: |
ANSIBLE_LIBRARY="." ANSIBLE_DOC_FRAGMENT_PLUGINS="." python utils/ansible-doc-test -v roles plugins ANSIBLE_LIBRARY="." ANSIBLE_DOC_FRAGMENT_PLUGINS="." python utils/ansible-doc-test -v roles plugins
check_docs_current: check_docs_current:
name: Check Ansible Documentation with ansible-core 2.15. name: Check Ansible Documentation with ansible-core 2.19.
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v4.1.1 - uses: actions/checkout@v4.1.1
@@ -48,9 +48,9 @@ jobs:
- uses: actions/setup-python@v5.1.0 - uses: actions/setup-python@v5.1.0
with: with:
python-version: '3.x' python-version: '3.x'
- name: Install Ansible 2.15 - name: Install Ansible 2.20
run: | run: |
python -m pip install "ansible-core >=2.15,<2.16" python -m pip install "ansible-core <2.20"
- name: Run ansible-doc-test - name: Run ansible-doc-test
run: | run: |
ANSIBLE_LIBRARY="." ANSIBLE_DOC_FRAGMENT_PLUGINS="." python utils/ansible-doc-test -v roles plugins ANSIBLE_LIBRARY="." ANSIBLE_DOC_FRAGMENT_PLUGINS="." python utils/ansible-doc-test -v roles plugins

View File

@@ -13,7 +13,7 @@ jobs:
fetch-depth: 0 fetch-depth: 0
- uses: actions/setup-python@v5.1.0 - uses: actions/setup-python@v5.1.0
with: with:
python-version: "3.x" python-version: "3.13"
- name: Run ansible-lint - name: Run ansible-lint
run: | run: |
pip install "ansible-core>=2.16,<2.17" 'ansible-lint==6.22' pip install "ansible-core>=2.16,<2.17" 'ansible-lint==6.22'

View File

@@ -6,7 +6,7 @@ pool:
vmImage: 'ubuntu-24.04' vmImage: 'ubuntu-24.04'
variables: variables:
ansible_version: "-core >=2.16,<2.17" ansible_version: "-core >=2.18,<2.19"
ansible_latest: "-core" ansible_latest: "-core"
ansible_minimum: "-core <2.16" ansible_minimum: "-core <2.16"
distros: "fedora-latest,c9s,c10s,fedora-rawhide" distros: "fedora-latest,c9s,c10s,fedora-rawhide"
@@ -36,7 +36,7 @@ stages:
# Supported distros # Supported distros
- ${{ each distro in split(variables.distros, ',') }}: - ${{ each distro in split(variables.distros, ',') }}:
- stage: ${{ replace(distro, '-', '_') }}_ansible_2_16 - stage: ${{ replace(distro, '-', '_') }}_ansible_2_18
dependsOn: [] dependsOn: []
jobs: jobs:
- template: templates/group_tests.yml - template: templates/group_tests.yml
@@ -49,7 +49,7 @@ stages:
# Galaxy on Fedora # Galaxy on Fedora
- stage: galaxy_fedora_latest_ansible_2_16 - stage: galaxy_fedora_latest_ansible_2_18
dependsOn: [] dependsOn: []
jobs: jobs:
- template: templates/group_tests.yml - template: templates/group_tests.yml

View File

@@ -18,7 +18,7 @@ variables:
distros: "fedora-latest,fedora-rawhide,c10s,c9s,c8s" distros: "fedora-latest,fedora-rawhide,c10s,c9s,c8s"
ansible_latest: "-core" ansible_latest: "-core"
ansible_minimum: "-core <2.16" ansible_minimum: "-core <2.16"
ansible_version: "-core >=2.16,<2.17" ansible_version: "-core >=2.18,<2.19"
stages: stages:

View File

@@ -5,16 +5,27 @@ trigger:
pool: pool:
vmImage: 'ubuntu-24.04' vmImage: 'ubuntu-24.04'
parameters:
# Not really a parameter, but variables cannot be arrays or dicts
# This maps the distro LATEST version to the avaiable ansible-core
# version of the latest released compose.
- name: "distro_ansible_map"
type: object
default:
- { distro: "c8s", ansible_version: "2.16" }
- { distro: "c9s", ansible_version: "2.14" }
- { distro: "c10s", ansible_version: "2.16" }
variables: variables:
distros: "fedora-latest,c10s,c9s,c8s,fedora-rawhide" distros: "fedora-latest,c10s,c9s,fedora-rawhide"
ansible_version: "-core >=2.15,<2.16" ansible_version: "-core >=2.18,<2.19"
stages: stages:
# Test with repository in all distros # Test with repository in all "current" distros
- ${{ each distro in split(variables.distros, ',') }}: - ${{ each distro in split(variables.distros, ',') }}:
- stage: ${{ replace(distro, '-', '_') }}_ansible_2_16 - stage: ${{ replace(distro, '-', '_') }}_ansible_2_18
dependsOn: [] dependsOn: []
jobs: jobs:
- template: templates/run_tests.yml - template: templates/run_tests.yml
@@ -27,7 +38,7 @@ stages:
# Galaxy on Fedora # Galaxy on Fedora
- stage: galaxy_fedora_latest_ansible_2_16 - stage: galaxy_fedora_latest_ansible_2_18
dependsOn: [] dependsOn: []
jobs: jobs:
- template: templates/run_tests.yml - template: templates/run_tests.yml
@@ -37,3 +48,18 @@ stages:
ansible_version: ${{ variables.ansible_version }} ansible_version: ${{ variables.ansible_version }}
skip_git_test: false skip_git_test: false
test_galaxy: true test_galaxy: true
# Test with pinned ansible version for the distro
- ${{ each config in parameters.distro_ansible_map }}:
- stage: ${{ config.distro }}_distro_ansible_${{ replace(config.ansible_version, '.', '_') }}
dependsOn: []
jobs:
- template: templates/run_tests.yml
parameters:
build_number: $(Build.BuildNumber)
distro: ${{ config.distro }}
ansible_version: -core==${{ config.ansible_version }}
skip_git_test: false
test_galaxy: false