diff options
author | Pluggi <pluggi512@gmail.com> | 2018-10-19 01:04:17 -0700 |
---|---|---|
committer | John R Barker <john@johnrbarker.com> | 2018-10-19 09:04:17 +0100 |
commit | f13091d142d3eea2ce94bf0c6b164039472c32a5 (patch) | |
tree | 3c24fa92eccf01074f4acfc886de44290fe4e380 /test/integration/targets/docker_container/tasks | |
parent | 131efcff9d42eba027aaa34168fcee4045a72ffd (diff) | |
download | ansible-f13091d142d3eea2ce94bf0c6b164039472c32a5.tar.gz |
Add runtime option to docker_container module (#47247)
* Add runtime option to docker_container module
Signed-off-by: Antoine Bardoux <abardoux@nvidia.com>
* Add changelog fragment
Signed-off-by: Antoine Bardoux <abardoux@nvidia.com>
* Add idempotency test for docker_container.runtime
Signed-off-by: Antoine Bardoux <abardoux@nvidia.com>
Diffstat (limited to 'test/integration/targets/docker_container/tasks')
-rw-r--r-- | test/integration/targets/docker_container/tasks/tests/options.yml | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/test/integration/targets/docker_container/tasks/tests/options.yml b/test/integration/targets/docker_container/tasks/tests/options.yml index 2db3ef40c4..9d3dc90809 100644 --- a/test/integration/targets/docker_container/tasks/tests/options.yml +++ b/test/integration/targets/docker_container/tasks/tests/options.yml @@ -2458,6 +2458,39 @@ - restart_retries_3 is changed #################################################################### +## runtime ######################################################### +#################################################################### + +- name: runtime + docker_container: + image: alpine:3.8 + command: '/bin/sh -v -c "sleep 10m"' + name: "{{ cname }}" + runtime: runc + state: started + register: runtime_1 + +- name: runtime (idempotency) + docker_container: + image: alpine:3.8 + command: '/bin/sh -v -c "sleep 10m"' + name: "{{ cname }}" + runtime: runc + state: started + register: runtime_2 + +- name: cleanup + docker_container: + name: "{{ cname }}" + state: absent + stop_timeout: 1 + +- assert: + that: + - runtime_1 is changed + - runtime_2 is not changed + +#################################################################### ## security_opts ################################################### #################################################################### |