mirror of
https://github.com/ansible-collections/community.docker.git
synced 2026-07-29 11:55:04 +00:00
Add basic podman tests to CI (#1040)
* Setup podman and run some basic tests with it. * Clean up Docker setup.
This commit is contained in:
@@ -13,3 +13,26 @@
|
||||
|
||||
- fail: msg="Too old docker / docker-py version to run docker_host_info tests!"
|
||||
when: not(docker_api_version is version('1.25', '>=')) and (ansible_distribution != 'CentOS' or ansible_distribution_major_version|int > 6)
|
||||
|
||||
- when: podman_cli_version is version('1.0.0', '>=')
|
||||
block:
|
||||
- name: Get Podman context
|
||||
community.docker.docker_context_info:
|
||||
name: podman
|
||||
register: docker_podman_context
|
||||
|
||||
- name: Run tests with Podman context
|
||||
module_defaults:
|
||||
group/community.docker.docker: "{{ docker_podman_context.contexts[0].config }}"
|
||||
block:
|
||||
|
||||
- name: Get info on Podman host
|
||||
docker_host_info:
|
||||
register: output
|
||||
|
||||
- name: Check for some Podman specific values
|
||||
assert:
|
||||
that:
|
||||
- output.host_info.ProductLicense == 'Apache-2.0'
|
||||
- >-
|
||||
"Rootless" in output.host_info
|
||||
|
||||
Reference in New Issue
Block a user