Zack Williams | e0d9eb9 | 2020-11-29 22:39:20 -0700 | [diff] [blame] | 1 | --- |
| 2 | # docker molecule/default/verify.yml |
| 3 | # |
| 4 | # SPDX-FileCopyrightText: © 2020 Open Networking Foundation <support@opennetworking.org> |
| 5 | # SPDX-License-Identifier: Apache-2.0 |
| 6 | |
| 7 | - name: Verify |
| 8 | hosts: all |
| 9 | tasks: |
| 10 | |
| 11 | - name: Check installed Docker version string |
| 12 | command: |
| 13 | cmd: "docker version" |
| 14 | register: docker_version |
| 15 | tags: |
| 16 | - skip_ansible_lint # info gathering |
| 17 | |
| 18 | - debug: |
| 19 | var: docker_version |
| 20 | |
| 21 | - name: Assert that installed Docker version matches version string |
| 22 | assert: |
| 23 | that: |
| 24 | - "'Version: 19.03' in docker_version.stdout" |
Hyunsun Moon | c272be6 | 2021-12-02 13:54:40 -0800 | [diff] [blame^] | 25 | |
| 26 | - name: Check docker daemon option exists |
| 27 | command: |
| 28 | cmd: "docker info -f {% raw %}'{{ index .RegistryConfig.Mirrors 0 }}'{% endraw %}" |
| 29 | register: docker_info |
| 30 | tags: |
| 31 | - skip_ansible_lint # info gathering |
| 32 | |
| 33 | - debug: |
| 34 | var: docker_info |
| 35 | |
| 36 | - name: Assert that installed Docker version matches version string |
| 37 | assert: |
| 38 | that: |
| 39 | - "'http://registry.aetherproject.net' in docker_info.stdout" |
| 40 | |
| 41 | - name: Check installed Docker compose version string |
| 42 | command: |
| 43 | cmd: "docker-compose --version" |
| 44 | register: docker_compose_version |
| 45 | tags: |
| 46 | - skip_ansible_lint # info gathering |
| 47 | |
| 48 | - debug: |
| 49 | var: docker_compose_version |
| 50 | |
| 51 | - name: Assert that installed Docker compose version matches version string |
| 52 | assert: |
| 53 | that: |
| 54 | - "'docker-compose version 1.29.2' in docker_compose_version.stdout" |