update ansible collections sops, docker and debops
All checks were successful
/ build (pull_request) Successful in 28s
/ Ansible Lint (push) Successful in 2m36s
/ Ansible Lint (pull_request) Successful in 2m41s

This commit is contained in:
chris 2026-09-21 22:26:20 +02:00
commit e31ee5e39c
Signed by: c6ristian
SSH key fingerprint: SHA256:B3m+yzpaxGXSEcDBpPHfvza/DNC0wuX+CKMeGq8wgak
131 changed files with 27667 additions and 19786 deletions

View file

@ -37,244 +37,116 @@ variables:
- name: coverageBranches
value: main
- name: entryPoint
value: tests/utils/shippable/shippable.sh
value: tests/utils/shippable/nox.sh
- name: prepareEntryPoint
value: tests/utils/shippable/nox-prepare.sh
- name: fetchDepth
value: 0
resources:
containers:
- container: default
image: quay.io/ansible/azure-pipelines-test-container:7.0.0
image: quay.io/ansible/azure-pipelines-test-container:8.0.0
pool: Standard
stages:
### Sanity & units
- stage: Ansible_devel
displayName: Sanity & Units devel
dependsOn: []
jobs:
- template: templates/matrix.yml
parameters:
targets:
- name: Sanity
test: 'devel/sanity/1'
- name: Units
test: 'devel/units/1'
- stage: Ansible_2_20
displayName: Sanity & Units 2.20
dependsOn: []
jobs:
- template: templates/matrix.yml
parameters:
targets:
- name: Sanity
test: '2.20/sanity/1'
- name: Units
test: '2.20/units/1'
- stage: Ansible_2_19
displayName: Sanity & Units 2.19
dependsOn: []
jobs:
- template: templates/matrix.yml
parameters:
targets:
- name: Sanity
test: '2.19/sanity/1'
- name: Units
test: '2.19/units/1'
- stage: Ansible_2_18
displayName: Sanity & Units 2.18
dependsOn: []
jobs:
- template: templates/matrix.yml
parameters:
targets:
- name: Sanity
test: '2.18/sanity/1'
- name: Units
test: '2.18/units/1'
### Docker
- stage: Docker_devel
displayName: Docker devel
dependsOn: []
jobs:
- template: templates/matrix.yml
parameters:
testFormat: devel/linux/{0}
targets:
- name: Fedora 42
test: fedora42
- name: Ubuntu 22.04
test: ubuntu2204
- name: Ubuntu 24.04
test: ubuntu2404
- name: Alpine 3.22
test: alpine322
groups:
- 4
- 5
- stage: Docker_2_20
displayName: Docker 2.20
dependsOn: []
jobs:
- template: templates/matrix.yml
parameters:
testFormat: 2.20/linux/{0}
targets:
- name: Fedora 42
test: fedora42
- name: Alpine 3.22
test: alpine322
groups:
- 4
- 5
- stage: Docker_2_19
displayName: Docker 2.19
dependsOn: []
jobs:
- template: templates/matrix.yml
parameters:
testFormat: 2.19/linux/{0}
targets:
- name: Fedora 41
test: fedora41
- name: Alpine 3.21
test: alpine321
groups:
- 4
- 5
- stage: Docker_2_18
displayName: Docker 2.18
dependsOn: []
jobs:
- template: templates/matrix.yml
parameters:
testFormat: 2.18/linux/{0}
targets:
- name: Fedora 40
test: fedora40
- name: Ubuntu 22.04
test: ubuntu2204
- name: Alpine 3.20
test: alpine320
groups:
- 4
- 5
### Community Docker
- stage: Docker_community_devel
displayName: Docker (community images) devel
dependsOn: []
jobs:
- template: templates/matrix.yml
parameters:
testFormat: devel/linux-community/{0}
targets:
- name: Debian 11 Bullseye
test: debian-bullseye/3.9
- name: Debian 12 Bookworm
test: debian-bookworm/3.11
- name: Debian 13 Trixie
test: debian-13-trixie/3.13
- name: ArchLinux
test: archlinux/3.13
groups:
- 4
- 5
### Remote
- stage: Remote_devel
displayName: Remote devel
dependsOn: []
jobs:
- template: templates/matrix.yml
parameters:
testFormat: devel/{0}
targets:
- name: RHEL 10.0
test: rhel/10.0
- name: RHEL 9.6 with Docker SDK, urllib3, requests from sources
test: rhel/9.6-dev-latest
# For some reason, Ubuntu 24.04 is *extremely* slower than RHEL 9.6
# - name: Ubuntu 24.04
# test: ubuntu/24.04
groups:
- 1
- 2
- 3
- 4
- 5
- stage: Remote_2_20
displayName: Remote 2.20
dependsOn: []
jobs:
- template: templates/matrix.yml
parameters:
testFormat: 2.20/{0}
targets:
- name: RHEL 9.6
test: rhel/9.6
groups:
- 1
- 2
- 3
- 4
- 5
- stage: Remote_2_19
- stage: remote_2_19
displayName: Remote 2.19
dependsOn: []
variables:
entryPoint: tests/utils/shippable/nox.sh
jobs:
- template: templates/matrix.yml
parameters:
testFormat: 2.19/{0}
targets:
- name: RHEL 9.5
test: rhel/9.5
- name: Ubuntu 22.04
test: ubuntu/22.04
groups:
- 1
- 2
- 3
- 4
- 5
- stage: Remote_2_18
displayName: Remote 2.18
dependsOn: []
jobs:
- template: templates/matrix.yml
parameters:
testFormat: 2.18/{0}
targets:
- name: RHEL 9.4
test: rhel/9.4
groups:
- 1
- 2
- 3
- 4
- 5
- name: Ubuntu 22.04 + group 1
test: ansible-test-integration-2.19-ubuntu-22.04-azp-1
- name: Ubuntu 22.04 + group 2
test: ansible-test-integration-2.19-ubuntu-22.04-azp-2
- name: Ubuntu 22.04 + group 3
test: ansible-test-integration-2.19-ubuntu-22.04-azp-3
- name: Ubuntu 22.04 + group 4
test: ansible-test-integration-2.19-ubuntu-22.04-azp-4
- name: Ubuntu 22.04 + group 5
test: ansible-test-integration-2.19-ubuntu-22.04-azp-5
## Finally
- stage: remote_2_20
displayName: Remote 2.20
dependsOn: []
variables:
entryPoint: tests/utils/shippable/nox.sh
jobs:
- template: templates/matrix.yml
parameters:
targets:
- name: RHEL 9.7 + group 1
test: ansible-test-integration-2.20-rhel-9.7-azp-1
- name: RHEL 9.7 + group 2
test: ansible-test-integration-2.20-rhel-9.7-azp-2
- name: RHEL 9.7 + group 3
test: ansible-test-integration-2.20-rhel-9.7-azp-3
- name: RHEL 9.7 + group 4
test: ansible-test-integration-2.20-rhel-9.7-azp-4
- name: RHEL 9.7 + group 5
test: ansible-test-integration-2.20-rhel-9.7-azp-5
- stage: remote_2_21
displayName: Remote 2.21
dependsOn: []
variables:
entryPoint: tests/utils/shippable/nox.sh
jobs:
- template: templates/matrix.yml
parameters:
targets:
- name: RHEL 10.1 + group 1
test: ansible-test-integration-2.21-rhel-10.1-azp-1
- name: RHEL 10.1 + group 2
test: ansible-test-integration-2.21-rhel-10.1-azp-2
- name: RHEL 10.1 + group 3
test: ansible-test-integration-2.21-rhel-10.1-azp-3
- name: RHEL 10.1 + group 4
test: ansible-test-integration-2.21-rhel-10.1-azp-4
- name: RHEL 10.1 + group 5
test: ansible-test-integration-2.21-rhel-10.1-azp-5
- stage: remote_devel
displayName: Remote devel
dependsOn: []
variables:
entryPoint: tests/utils/shippable/nox.sh
jobs:
- template: templates/matrix.yml
parameters:
targets:
- name: RHEL 10.2 + group 1 + sdk-dev-latest
test: ansible-test-integration-devel-rhel-10.2-azp-1
- name: RHEL 10.2 + group 2 + sdk-dev-latest
test: ansible-test-integration-devel-rhel-10.2-azp-2
- name: RHEL 10.2 + group 3 + sdk-dev-latest
test: ansible-test-integration-devel-rhel-10.2-azp-3
- name: RHEL 10.2 + group 4 + sdk-dev-latest
test: ansible-test-integration-devel-rhel-10.2-azp-4
- name: RHEL 10.2 + group 5 + sdk-dev-latest
test: ansible-test-integration-devel-rhel-10.2-azp-5
- name: RHEL 9.8 + group 1
test: ansible-test-integration-devel-rhel-9.8-azp-1
- name: RHEL 9.8 + group 2
test: ansible-test-integration-devel-rhel-9.8-azp-2
- name: RHEL 9.8 + group 3
test: ansible-test-integration-devel-rhel-9.8-azp-3
- name: RHEL 9.8 + group 4
test: ansible-test-integration-devel-rhel-9.8-azp-4
- name: RHEL 9.8 + group 5
test: ansible-test-integration-devel-rhel-9.8-azp-5
- stage: Summary
condition: succeededOrFailed()
dependsOn:
- Ansible_devel
- Ansible_2_20
- Ansible_2_19
- Ansible_2_18
- Remote_devel
- Remote_2_20
- Remote_2_19
- Remote_2_18
- Docker_devel
- Docker_2_20
- Docker_2_19
- Docker_2_18
- Docker_community_devel
- remote_2_19
- remote_2_20
- remote_2_21
- remote_devel
jobs:
- template: templates/coverage.yml

View file

@ -1,10 +1,10 @@
#!/usr/bin/env bash
# Aggregate code coverage results for later processing.
# Copyright (c) Ansible Project
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
# Aggregate code coverage results for later processing.
set -o pipefail -eu
agent_temp_directory="$1"
@ -13,10 +13,6 @@ PATH="${PWD}/bin:${PATH}"
mkdir "${agent_temp_directory}/coverage/"
if [[ "$(ansible --version)" =~ \ 2\.9\. ]]; then
exit
fi
options=(--venv --venv-system-site-packages --color -v)
ansible-test coverage combine --group-by command --export "${agent_temp_directory}/coverage/" "${options[@]}"

View file

@ -11,8 +11,7 @@ Keep in mind that Azure Pipelines does not enforce unique job display names (onl
It is up to pipeline authors to avoid name collisions when deviating from the recommended format.
"""
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
from __future__ import annotations
import os
import re
@ -24,12 +23,12 @@ def main():
"""Main program entry point."""
source_directory = sys.argv[1]
if '/ansible_collections/' in os.getcwd():
if "/ansible_collections/" in os.getcwd():
output_path = "tests/output"
else:
output_path = "test/results"
destination_directory = os.path.join(output_path, 'coverage')
destination_directory = os.path.join(output_path, "coverage")
if not os.path.exists(destination_directory):
os.makedirs(destination_directory)
@ -38,27 +37,27 @@ def main():
count = 0
for name in os.listdir(source_directory):
match = re.search('^Coverage (?P<attempt>[0-9]+) (?P<label>.+)$', name)
label = match.group('label')
attempt = int(match.group('attempt'))
match = re.search("^Coverage (?P<attempt>[0-9]+) (?P<label>.+)$", name)
label = match.group("label")
attempt = int(match.group("attempt"))
jobs[label] = max(attempt, jobs.get(label, 0))
for label, attempt in jobs.items():
name = 'Coverage {attempt} {label}'.format(label=label, attempt=attempt)
name = f"Coverage {attempt} {label}"
source = os.path.join(source_directory, name)
source_files = os.listdir(source)
for source_file in source_files:
source_path = os.path.join(source, source_file)
destination_path = os.path.join(destination_directory, source_file + '.' + label)
print('"%s" -> "%s"' % (source_path, destination_path))
destination_path = os.path.join(destination_directory, source_file + "." + label)
print(f'"{source_path}" -> "{destination_path}"')
shutil.copyfile(source_path, destination_path)
count += 1
print('Coverage file count: %d' % count)
print('##vso[task.setVariable variable=coverageFileCount]%d' % count)
print('##vso[task.setVariable variable=outputPath]%s' % output_path)
print(f"Coverage file count: {count}")
print(f"##vso[task.setVariable variable=coverageFileCount]{count}")
print(f"##vso[task.setVariable variable=outputPath]{output_path}")
if __name__ == '__main__':
if __name__ == "__main__":
main()

View file

@ -1,10 +1,10 @@
#!/usr/bin/env bash
# Check the test results and set variables for use in later steps.
# Copyright (c) Ansible Project
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
# Check the test results and set variables for use in later steps.
set -o pipefail -eu
if [[ "$PWD" =~ /ansible_collections/ ]]; then

View file

@ -15,7 +15,6 @@ import pathlib
import shutil
import subprocess
import tempfile
import typing as t
import urllib.request
@ -23,7 +22,7 @@ import urllib.request
class CoverageFile:
name: str
path: pathlib.Path
flags: t.List[str]
flags: list[str]
@dataclasses.dataclass(frozen=True)
@ -34,8 +33,8 @@ class Args:
def parse_args() -> Args:
parser = argparse.ArgumentParser()
parser.add_argument('-n', '--dry-run', action='store_true')
parser.add_argument('path', type=pathlib.Path)
parser.add_argument("-n", "--dry-run", action="store_true")
parser.add_argument("path", type=pathlib.Path)
args = parser.parse_args()
@ -46,32 +45,36 @@ def parse_args() -> Args:
return Args(**kwargs)
def process_files(directory: pathlib.Path) -> t.Tuple[CoverageFile, ...]:
def process_files(directory: pathlib.Path) -> tuple[CoverageFile, ...]:
processed = []
for file in directory.joinpath('reports').glob('coverage*.xml'):
name = file.stem.replace('coverage=', '')
for file in directory.joinpath("reports").glob("coverage*.xml"):
name = file.stem.replace("coverage=", "")
# Get flags from name
flags = name.replace('-powershell', '').split('=') # Drop '-powershell' suffix
flags = [flag if not flag.startswith('stub') else flag.split('-')[0] for flag in flags] # Remove "-01" from stub files
flags = name.replace("-powershell", "").split("=") # Drop '-powershell' suffix
flags = [
flag if not flag.startswith("stub") else flag.split("-")[0] for flag in flags
] # Remove "-01" from stub files
processed.append(CoverageFile(name, file, flags))
return tuple(processed)
def upload_files(codecov_bin: pathlib.Path, files: t.Tuple[CoverageFile, ...], dry_run: bool = False) -> None:
def upload_files(codecov_bin: pathlib.Path, files: tuple[CoverageFile, ...], dry_run: bool = False) -> None:
for file in files:
cmd = [
str(codecov_bin),
'--name', file.name,
'--file', str(file.path),
"--name",
file.name,
"--file",
str(file.path),
]
for flag in file.flags:
cmd.extend(['--flags', flag])
cmd.extend(["--flags", flag])
if dry_run:
print(f'DRY-RUN: Would run command: {cmd}')
print(f"DRY-RUN: Would run command: {cmd}")
continue
subprocess.run(cmd, check=True)
@ -79,11 +82,11 @@ def upload_files(codecov_bin: pathlib.Path, files: t.Tuple[CoverageFile, ...], d
def download_file(url: str, dest: pathlib.Path, flags: int, dry_run: bool = False) -> None:
if dry_run:
print(f'DRY-RUN: Would download {url} to {dest} and set mode to {flags:o}')
print(f"DRY-RUN: Would download {url} to {dest} and set mode to {flags:o}")
return
with urllib.request.urlopen(url) as resp:
with dest.open('w+b') as f:
with dest.open("w+b") as f:
# Read data in chunks rather than all at once
shutil.copyfileobj(resp, f, 64 * 1024)
@ -92,14 +95,14 @@ def download_file(url: str, dest: pathlib.Path, flags: int, dry_run: bool = Fals
def main():
args = parse_args()
url = 'https://ansible-ci-files.s3.amazonaws.com/codecov/linux/codecov'
with tempfile.TemporaryDirectory(prefix='codecov-') as tmpdir:
codecov_bin = pathlib.Path(tmpdir) / 'codecov'
url = "https://ansible-ci-files.s3.amazonaws.com/codecov/linux/codecov"
with tempfile.TemporaryDirectory(prefix="codecov-") as tmpdir:
codecov_bin = pathlib.Path(tmpdir) / "codecov"
download_file(url, codecov_bin, 0o755, args.dry_run)
files = process_files(args.path)
upload_files(codecov_bin, files, args.dry_run)
if __name__ == '__main__':
if __name__ == "__main__":
main()

View file

@ -1,18 +1,14 @@
#!/usr/bin/env bash
# Generate code coverage reports for uploading to Azure Pipelines and codecov.io.
# Copyright (c) Ansible Project
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
# Generate code coverage reports for uploading to Azure Pipelines and codecov.io.
set -o pipefail -eu
PATH="${PWD}/bin:${PATH}"
if [[ "$(ansible --version)" =~ \ 2\.9\. ]]; then
exit
fi
if ! ansible-test --help >/dev/null 2>&1; then
# Install the devel version of ansible-test for generating code coverage reports.
# This is only used by Ansible Collections, which are typically tested against multiple Ansible versions (in separate jobs).

View file

@ -1,20 +1,22 @@
#!/usr/bin/env bash
# Configure the test environment and run the tests.
# Copyright (c) Ansible Project
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
# SPDX-License-Identifier: GPL-3.0-or-later
# Configure the test environment and run the tests.
set -o pipefail -eu
entry_point="$1"
test="$2"
read -r -a coverage_branches <<< "$3" # space separated list of branches to run code coverage on for scheduled builds
agent_temp_directory="$4"
export COMMIT_MESSAGE
export COMPLETE
export COVERAGE
export IS_PULL_REQUEST
export COVERAGE_DESTINATION_DIRECTORY="${agent_temp_directory}/coverage"
if [ "${SYSTEM_PULLREQUEST_TARGETBRANCH:-}" ]; then
IS_PULL_REQUEST=true

View file

@ -5,8 +5,7 @@
"""Prepends a relative timestamp to each input line from stdin and writes it to stdout."""
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
from __future__ import annotations
import sys
import time
@ -16,14 +15,14 @@ def main():
"""Main program entry point."""
start = time.time()
sys.stdin.reconfigure(errors='surrogateescape')
sys.stdout.reconfigure(errors='surrogateescape')
sys.stdin.reconfigure(errors="surrogateescape")
sys.stdout.reconfigure(errors="surrogateescape")
for line in sys.stdin:
seconds = time.time() - start
sys.stdout.write('%02d:%02d %s' % (seconds // 60, seconds % 60, line))
seconds = int(time.time() - start)
sys.stdout.write(f"{seconds // 60:02}:{seconds % 60:02} {line}")
sys.stdout.flush()
if __name__ == '__main__':
if __name__ == "__main__":
main()

View file

@ -23,14 +23,16 @@ jobs:
- checkout: self
fetchDepth: $(fetchDepth)
path: $(checkoutPath)
- bash: .azure-pipelines/scripts/run-tests.sh "$(entryPoint)" "${{ job.test }}" "$(coverageBranches)"
- bash: .azure-pipelines/scripts/run-tests.sh "$(prepareEntryPoint)" "${{ job.test }}" "$(coverageBranches)" "$(Agent.TempDirectory)"
displayName: Prepare Tests
- bash: .azure-pipelines/scripts/run-tests.sh "$(entryPoint)" "${{ job.test }}" "$(coverageBranches)" "$(Agent.TempDirectory)"
displayName: Run Tests
- bash: .azure-pipelines/scripts/process-results.sh
condition: succeededOrFailed()
displayName: Process Results
- bash: .azure-pipelines/scripts/aggregate-coverage.sh "$(Agent.TempDirectory)"
condition: eq(variables.haveCoverageData, 'true')
displayName: Aggregate Coverage Data
# - bash: .azure-pipelines/scripts/aggregate-coverage.sh "$(Agent.TempDirectory)"
# condition: eq(variables.haveCoverageData, 'true')
# displayName: Aggregate Coverage Data
- task: PublishTestResults@2
condition: eq(variables.haveTestResults, 'true')
inputs:

View file

@ -28,7 +28,7 @@ env:
jobs:
build:
name: Build image ${{ matrix.name }}:${{ matrix.tag }}
runs-on: ubuntu-24.04
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
@ -43,9 +43,13 @@ jobs:
tag: check
tag-as-latest: true
permissions:
contents: read
packages: write
steps:
- name: Check out repository
uses: actions/checkout@v6
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
@ -53,10 +57,10 @@ jobs:
run: |
sudo apt-get install podman buildah
- name: Set up Go 1.22
uses: actions/setup-go@v6
- name: Set up Go 1.26
uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version: '1.22'
go-version: '1.26'
cache: false # true (default) results in warnings since we don't use Go modules
- name: Build ${{ matrix.name }} image
@ -66,25 +70,22 @@ jobs:
- name: Tag image as latest
if: matrix.tag-as-latest && matrix.tag != 'latest'
run: |
podman tag "${CONTAINER_REGISTRY}/${{ matrix.name }}:${{ matrix.tag }}" "${CONTAINER_REGISTRY}/${{ matrix.name }}:latest"
env:
SOURCE_IMAGE: ${{ matrix.name }}:${{ matrix.tag }}
DEST_IMAGE: ${{ matrix.name }}:latest
run: >-
podman tag "${CONTAINER_REGISTRY}/${SOURCE_IMAGE}" "${CONTAINER_REGISTRY}/${DEST_IMAGE}"
- name: Publish container image ${{ env.CONTAINER_REGISTRY }}/${{ matrix.name }}:${{ matrix.tag }}
if: github.event_name != 'pull_request'
uses: redhat-actions/push-to-registry@v2
with:
registry: ${{ env.CONTAINER_REGISTRY }}
image: ${{ matrix.name }}
tags: ${{ matrix.tag }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
env:
IMAGE: ${{ matrix.name }}:${{ matrix.tag }}
run: >-
podman manifest push --all "${IMAGE}" "${CONTAINER_REGISTRY}/${IMAGE}" --tls-verify=true --creds=${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}
- name: Publish container image ${{ env.CONTAINER_REGISTRY }}/${{ matrix.name }}:latest
if: github.event_name != 'pull_request' && matrix.tag-as-latest && matrix.tag != 'latest'
uses: redhat-actions/push-to-registry@v2
with:
registry: ${{ env.CONTAINER_REGISTRY }}
image: ${{ matrix.name }}
tags: latest
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
env:
IMAGE: ${{ matrix.name }}:latest
run: >-
podman manifest push --all "${IMAGE}" "${CONTAINER_REGISTRY}/${IMAGE}" --tls-verify=true --creds=${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}

View file

@ -15,6 +15,14 @@ name: nox
- cron: '0 9 * * *'
workflow_dispatch:
permissions:
contents: read
concurrency:
# Make sure there is at most one active run per PR, but do not cancel any non-PR runs
group: ${{ github.workflow }}-${{ (github.head_ref && github.event.number) || github.run_id }}
cancel-in-progress: true
jobs:
nox:
uses: ansible-community/antsibull-nox/.github/workflows/reusable-nox-run.yml@main
@ -30,6 +38,6 @@ jobs:
upload-codecov-pr: false
upload-codecov-push: false
upload-codecov-schedule: true
max-ansible-core: "2.17"
allow-coverage-cd-override: true
secrets:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

File diff suppressed because it is too large Load diff

View file

@ -4,6 +4,87 @@ Docker Community Collection Release Notes
.. contents:: Topics
v5.3.0
======
Release Summary
---------------
Feature release.
Minor Changes
-------------
- docker_swarm_service - add ``command_as_args`` option. When set to ``true``, ``command`` and ``args`` are concatenated and mapped to ``ContainerSpec.Args`` (matching ``docker service create IMAGE [COMMAND] [ARG...]``), preserving the image ``ENTRYPOINT``. The default remains ``false`` (historical mapping of ``command`` to ``ContainerSpec.Command`` and ``args`` to ``ContainerSpec.Args``) for backward compatibility (https://github.com/ansible-collections/community.docker/issues/1044, https://github.com/ansible-collections/community.docker/issues/212, https://github.com/ansible-collections/community.docker/pull/1307).
v5.2.2
======
Release Summary
---------------
Bugfix release.
Bugfixes
--------
- Handle empty 'docker compose images' stdout in case of errors (https://github.com/ansible-collections/community.docker/pull/1305).
- docker_api connection plugin - the environment fallbacks for ``docker_host``, ``tls_hostname``, ``api_version``, ``timeout``, ``tls``, and ``validate_certs`` now finally work (https://github.com/ansible-collections/community.docker/issues/1298, https://github.com/ansible-collections/community.docker/pull/1299).
- docker_containers inventory plugin - the environment fallbacks for ``docker_host``, ``tls_hostname``, ``api_version``, ``timeout``, ``tls``, and ``validate_certs`` now finally work (https://github.com/ansible-collections/community.docker/issues/1298, https://github.com/ansible-collections/community.docker/pull/1299).
- docker_image, docker_image_pull, docker_container - also handle errors if only ``errorDetail`` is set, but not ``error``. The ``error`` field has been `deprecated in Moby apparently a very long time ago <https://github.com/moby/moby/commit/3043c2641990d94298c6377b7ef14709263a4709>`__ (https://github.com/ansible-collections/community.docker/pull/1302).
v5.2.1
======
Release Summary
---------------
Bugfix release.
Bugfixes
--------
- docker_container_exec module, docker_api connection plugin - ensure that when a command is run in a container with stdin provided, that the actual response is closed and not a socket derived from it. The old behavior causes warnings to be shown on Python 3.13+ under certain conditions (https://github.com/ansible-collections/community.docker/issues/1247, https://github.com/ansible-collections/community.docker/pull/1260).
v5.2.0
======
Release Summary
---------------
Feature release.
Minor Changes
-------------
- docker_image_export - adds ``platform`` parameter to allow exporting a specific platform variant from a multi-arch image (https://github.com/ansible-collections/community.docker/issues/1064, https://github.com/ansible-collections/community.docker/pull/1251).
v5.1.0
======
Release Summary
---------------
Feature release.
Minor Changes
-------------
- docker_compose_v2_pull - adds ``ignore_pull_failures`` parameter that passes ``--ignore-pull-failures`` to the ``docker compose pull`` call when set to ``true`` (https://github.com/ansible-collections/community.docker/pull/1248).
v5.0.6
======
Release Summary
---------------
Bugfix release.
Bugfixes
--------
- docker_image_pull, docker_container - fix pulled image change detection for Docker 29.2+ (https://github.com/ansible-collections/community.docker/pull/1242).
v5.0.5
======

File diff suppressed because it is too large Load diff

View file

@ -2,7 +2,7 @@
"collection_info": {
"namespace": "community",
"name": "docker",
"version": "5.0.5",
"version": "5.3.0",
"authors": [
"Ansible Docker Working Group"
],
@ -28,7 +28,7 @@
"name": "FILES.json",
"ftype": "file",
"chksum_type": "sha256",
"chksum_sha256": "1aa5979880106388e42eb161e2d88931ab8a128b982afd506536bed31a71c176",
"chksum_sha256": "eb242635f86c2b8822011d87dd69bd17ff371f5ddeb89f9961001fa28c705e85",
"format": 1
},
"format": 1

View file

@ -38,7 +38,7 @@ For more information about communication, see the [Ansible communication guide](
## Tested with Ansible
Tested with the current ansible-core 2.17, ansible-core 2.18, and ansible-core 2.19 releases, and the current development version of ansible-core. Ansible/ansible-base versions before 2.17.0 are not supported.
Tested with the current ansible-core 2.17, ansible-core 2.18, ansible-core 2.19, ansible-core 2.20, ansible-core 2.21 releases, and the current development version of ansible-core. Ansible/ansible-base versions before 2.17.0 are not supported.
## External requirements

View file

@ -4,10 +4,15 @@
[collection_sources]
"ansible.posix" = "git+https://github.com/ansible-collections/ansible.posix.git,main"
"community.crypto" = "git+https://github.com/ansible-collections/community.crypto.git,main"
"community.general" = "git+https://github.com/ansible-collections/community.general.git,main"
"community.internal_test_tools" = "git+https://github.com/ansible-collections/community.internal_test_tools.git,main"
"community.library_inventory_filtering_v1" = "git+https://github.com/ansible-collections/community.library_inventory_filtering.git,stable-1"
[collection_sources_per_ansible.'2.17']
# community.general's main branch needs ansible-core >= 2.18
"community.general" = "git+https://github.com/ansible-collections/community.general.git,stable-12"
[vcs]
vcs = "git"
development_branch = "main"
@ -98,13 +103,28 @@ include_devel = true
[sessions.ansible_test_integration]
session_name_template = "ansible-test-integration-{ansible_core}{dash_docker_short}{dash_remote}{dash_python_version}{dash_target_dashized}"
display_name_template = "main+Ⓐ{ansible_core}{plus_docker_short}{plus_remote}{plus_py_python_version}{plus_target}{plus_force_docker_sdk_for_python_dev}{plus_force_docker_sdk_for_python_pypi}"
description_template = "Run main integration tests with ansible-core {ansible_core}{comma_docker_short}{comma_remote}{comma_py_python_version}{comma_target}{comma_force_docker_sdk_for_python_dev}{comma_force_docker_sdk_for_python_pypi}"
display_name_template = "Ⓐ{ansible_core}{plus_docker_nice}{plus_remote_nice}{plus_py_python_version}{plus_target_nice}{plus_force_docker_sdk_for_python_dev}{plus_force_docker_sdk_for_python_pypi}"
description_template = "Run integration tests with ansible-core {ansible_core}{comma_docker_nice}{comma_remote_nice}{comma_py_python_version}{comma_target_nice}{comma_force_docker_sdk_for_python_dev}{comma_force_docker_sdk_for_python_pypi}"
retry_on_error = "in-ci"
[sessions.ansible_test_integration.ansible_vars]
force_docker_sdk_for_python_dev = { type = "value", value = false, template_value = "" }
force_docker_sdk_for_python_pypi = { type = "value", value = false, template_value = "" }
[sessions.ansible_test_integration.nice_target_names]
"azp/1/" = "group 1"
"azp/2/" = "group 2"
"azp/3/" = "group 3"
"azp/4/" = "group 4"
"azp/5/" = "group 5"
[sessions.ansible_test_integration.nice_docker_names]
"quay.io/ansible-community/test-image:debian-bullseye" = "Debian 11"
"quay.io/ansible-community/test-image:debian-bookworm" = "Debian 12"
"quay.io/ansible-community/test-image:debian-13-trixie" = "Debian 13"
"quay.io/ansible-community/test-image:archlinux" = "Arch Linux"
"quay.io/ansible-community/test-image:opensuse-tumbleweed" = "OpenSuSE Tumbleweed"
##################################################################################################
# Ansible-core 2.17:
@ -137,7 +157,7 @@ docker = [ "fedora40", "ubuntu2204", "alpine320" ]
[[sessions.ansible_test_integration.groups.sessions]]
ansible_core = "2.18"
target = [ "azp/1/", "azp/2/", "azp/3/", "azp/4/", "azp/5/" ]
remote = [ "rhel/9.4" ]
remote = [ "rhel/9.7" ]
# Ansible-core 2.19:
@ -153,7 +173,7 @@ docker = [ "fedora41", "alpine321" ]
[[sessions.ansible_test_integration.groups.sessions]]
ansible_core = "2.19"
target = [ "azp/1/", "azp/2/", "azp/3/", "azp/4/", "azp/5/" ]
remote = [ "rhel/9.5", "ubuntu/22.04" ]
remote = [ "ubuntu/22.04" ]
# Ansible-core 2.20:
@ -169,7 +189,23 @@ docker = [ "fedora42", "alpine322" ]
[[sessions.ansible_test_integration.groups.sessions]]
ansible_core = "2.20"
target = [ "azp/1/", "azp/2/", "azp/3/", "azp/4/", "azp/5/" ]
remote = [ "rhel/9.6" ]
remote = [ "rhel/9.7" ]
# Ansible-core 2.21:
[[sessions.ansible_test_integration.groups]]
session_name = "ansible-test-integration-2.21"
description = "Meta session for running all ansible-test-integration-2.21-* sessions."
[[sessions.ansible_test_integration.groups.sessions]]
ansible_core = "2.21"
target = [ "azp/4/", "azp/5/" ]
docker = [ "fedora43", "ubuntu2204", "ubuntu2404", "alpine323" ]
[[sessions.ansible_test_integration.groups.sessions]]
ansible_core = "2.21"
target = [ "azp/1/", "azp/2/", "azp/3/", "azp/4/", "azp/5/" ]
remote = [ "rhel/10.1" ]
# Ansible-core devel:
@ -180,7 +216,7 @@ description = "Meta session for running all ansible-test-integration-devel-* ses
[[sessions.ansible_test_integration.groups.sessions]]
ansible_core = "devel"
target = [ "azp/4/", "azp/5/" ]
docker = [ "fedora42", "ubuntu2204", "ubuntu2404", "alpine322" ]
docker = [ "fedora44", "ubuntu2404", "ubuntu2604", "alpine324" ]
[[sessions.ansible_test_integration.groups.sessions]]
ansible_core = "devel"
@ -204,19 +240,25 @@ docker = "quay.io/ansible-community/test-image:debian-13-trixie"
ansible_core = "devel"
target = [ "azp/4/", "azp/5/" ]
python_version = "3.13"
docker = "quay.io/ansible-community/test-image:opensuse-tumbleweed"
[[sessions.ansible_test_integration.groups.sessions]]
ansible_core = "devel"
target = [ "azp/4/", "azp/5/" ]
python_version = "3.14"
docker = "quay.io/ansible-community/test-image:archlinux"
[[sessions.ansible_test_integration.groups.sessions]]
ansible_core = "devel"
target = [ "azp/1/", "azp/2/", "azp/3/", "azp/4/", "azp/5/" ]
remote = [ "rhel/9.6" ]
remote = [ "rhel/10.2" ]
ansible_vars = { force_docker_sdk_for_python_dev = { type = "value", value = true, template_value = "sdk-dev-latest" } }
[[sessions.ansible_test_integration.groups.sessions]]
ansible_core = "devel"
target = [ "azp/1/", "azp/2/", "azp/3/", "azp/4/", "azp/5/" ]
remote = [
"rhel/10.0",
"rhel/9.8",
# For some reason, Ubuntu 24.04 is *extremely* slower than RHEL 9.6
# "ubuntu/24.04",
]
@ -226,14 +268,14 @@ remote = [
[sessions.ansible_lint]
[[sessions.ee_check.execution_environments]]
name = "devel-ubi-9"
description = "ansible-core devel @ RHEL UBI 9"
name = "devel-ubi-10"
description = "ansible-core devel @ RHEL UBI 10"
test_playbooks = ["tests/ee/all.yml"]
config.images.base_image.name = "docker.io/redhat/ubi9:latest"
config.images.base_image.name = "docker.io/redhat/ubi10:latest"
config.dependencies.ansible_core.package_pip = "https://github.com/ansible/ansible/archive/devel.tar.gz"
config.dependencies.ansible_runner.package_pip = "ansible-runner"
config.dependencies.python_interpreter.package_system = "python3.12 python3.12-pip python3.12-wheel python3.12-cryptography"
config.dependencies.python_interpreter.python_path = "/usr/bin/python3.12"
config.dependencies.python_interpreter.package_system = "python3.14 python3.14-pip python3.14-cryptography"
config.dependencies.python_interpreter.python_path = "/usr/bin/python3.14"
runtime_environment = {"ANSIBLE_PRIVATE_ROLE_VARS" = "true"}
runtime_container_options = [
# Mount Docker socket into the container so we can talk to Docker outside the container

View file

@ -2357,3 +2357,86 @@ releases:
- 1226-docker-sdk-tls.yml
- 5.0.5.yml
release_date: '2025-12-31'
5.0.6:
changes:
bugfixes:
- docker_image_pull, docker_container - fix pulled image change detection
for Docker 29.2+ (https://github.com/ansible-collections/community.docker/pull/1242).
release_summary: Bugfix release.
fragments:
- 1242-pull.yml
- 5.0.6.yml
release_date: '2026-02-12'
5.1.0:
changes:
minor_changes:
- docker_compose_v2_pull - adds ``ignore_pull_failures`` parameter that passes
``--ignore-pull-failures`` to the ``docker compose pull`` call when set
to ``true`` (https://github.com/ansible-collections/community.docker/pull/1248).
release_summary: Feature release.
fragments:
- 1248-ignore-pull-failures.yml
- 5.1.0.yml
release_date: '2026-03-23'
5.2.0:
changes:
minor_changes:
- docker_image_export - adds ``platform`` parameter to allow exporting a specific
platform variant from a multi-arch image (https://github.com/ansible-collections/community.docker/issues/1064,
https://github.com/ansible-collections/community.docker/pull/1251).
release_summary: Feature release.
fragments:
- 1064-docker-image-export-platform.yml
- 5.2.0.yml
release_date: '2026-04-08'
5.2.1:
changes:
bugfixes:
- docker_container_exec module, docker_api connection plugin - ensure that
when a command is run in a container with stdin provided, that the actual
response is closed and not a socket derived from it. The old behavior causes
warnings to be shown on Python 3.13+ under certain conditions (https://github.com/ansible-collections/community.docker/issues/1247,
https://github.com/ansible-collections/community.docker/pull/1260).
release_summary: Bugfix release.
fragments:
- 1260-close.yml
- 5.2.1.yml
release_date: '2026-05-26'
5.2.2:
changes:
bugfixes:
- Handle empty 'docker compose images' stdout in case of errors (https://github.com/ansible-collections/community.docker/pull/1305).
- docker_api connection plugin - the environment fallbacks for ``docker_host``,
``tls_hostname``, ``api_version``, ``timeout``, ``tls``, and ``validate_certs``
now finally work (https://github.com/ansible-collections/community.docker/issues/1298,
https://github.com/ansible-collections/community.docker/pull/1299).
- docker_containers inventory plugin - the environment fallbacks for ``docker_host``,
``tls_hostname``, ``api_version``, ``timeout``, ``tls``, and ``validate_certs``
now finally work (https://github.com/ansible-collections/community.docker/issues/1298,
https://github.com/ansible-collections/community.docker/pull/1299).
- docker_image, docker_image_pull, docker_container - also handle errors if
only ``errorDetail`` is set, but not ``error``. The ``error`` field has
been `deprecated in Moby apparently a very long time ago <https://github.com/moby/moby/commit/3043c2641990d94298c6377b7ef14709263a4709>`__
(https://github.com/ansible-collections/community.docker/pull/1302).
release_summary: Bugfix release.
fragments:
- 1299-env.yml
- 1302-docker-image.yml
- 1305-docker-compose.yml
- 5.2.2.yml
release_date: '2026-08-08'
5.3.0:
changes:
minor_changes:
- docker_swarm_service - add ``command_as_args`` option. When set to ``true``,
``command`` and ``args`` are concatenated and mapped to ``ContainerSpec.Args``
(matching ``docker service create IMAGE [COMMAND] [ARG...]``), preserving
the image ``ENTRYPOINT``. The default remains ``false`` (historical mapping
of ``command`` to ``ContainerSpec.Command`` and ``args`` to ``ContainerSpec.Args``)
for backward compatibility (https://github.com/ansible-collections/community.docker/issues/1044,
https://github.com/ansible-collections/community.docker/issues/212, https://github.com/ansible-collections/community.docker/pull/1307).
release_summary: Feature release.
fragments:
- 1044-swarm-service-command-args.yml
- 5.3.0.yml
release_date: '2026-09-06'

View file

@ -12,6 +12,7 @@ import nox
try:
import antsibull_nox
from antsibull_nox.cli import run as run_antsibull_nox
except ImportError:
print("You need to install antsibull-nox in the same Python environment as nox.")
sys.exit(1)
@ -20,6 +21,24 @@ except ImportError:
antsibull_nox.load_antsibull_nox_toml()
@nox.session(name="update-azp-config", python=False)
def update_azp_config(session: nox.Session) -> None:
command = [
"antsibull-nox",
"update-azp-config",
"--exclude-tags",
"docker",
"--min-ansible-core",
"2.19",
]
if antsibull_nox.IN_CI:
command.append("--fail-on-change")
session.debug(" ".join(command))
result = run_antsibull_nox(command)
if result != 0:
session.error(f"Execution failed with status code {result}")
# Allow to run the noxfile with `python noxfile.py`, `pipx run noxfile.py`, or similar.
# Requires nox >= 2025.02.09
if __name__ == "__main__":

View file

@ -19,6 +19,7 @@ notes:
with Python's C(SSLSocket)s. See U(https://github.com/ansible-collections/community.docker/issues/605) for more information.
extends_documentation_fragment:
- community.docker._docker.api_documentation
- community.docker._docker.api_environment_documentation
- community.docker._docker.var_names
options:
remote_user:
@ -303,7 +304,7 @@ class Connection(ConnectionBase):
data = {"Tty": False, "Detach": False}
if need_stdin:
exec_socket = self._call_client(
exec_socket, response = self._call_client(
lambda client: client.post_json_to_stream_socket(
"/exec/{0}/start", exec_id, data=data
)
@ -356,7 +357,7 @@ class Connection(ConnectionBase):
stdout, stderr = exec_socket_handler.consume()
finally:
exec_socket.close()
response.close()
else:
stdout, stderr = self._call_client(
lambda client: client.post_json_to_stream(

Some files were not shown because too many files have changed in this diff Show more