[WIP] Fix CI (#50)

* Centralize location of images for runme.sh tests.

* Switch images.

* Fix sanity.

* Fix image names.

* Fix tag chaos.

* One more.
This commit is contained in:
Felix Fontein
2020-12-15 13:57:38 +01:00
committed by GitHub
parent fe2d52ff29
commit ebafa17b02
17 changed files with 60 additions and 61 deletions
@@ -5,14 +5,14 @@
- name: Make sure image is not there
docker_image:
name: "{{ docker_test_image_hello_world }}:latest"
name: "{{ docker_test_image_hello_world }}"
state: absent
force_absent: yes
register: absent_1
- name: Make sure image is not there (idempotency)
docker_image:
name: "{{ docker_test_image_hello_world }}:latest"
name: "{{ docker_test_image_hello_world }}"
state: absent
register: absent_2
@@ -22,14 +22,14 @@
- name: Make sure image is there
docker_image:
name: "{{ docker_test_image_hello_world }}:latest"
name: "{{ docker_test_image_hello_world }}"
state: present
source: pull
register: present_1
- name: Make sure image is there (idempotent)
docker_image:
name: "{{ docker_test_image_hello_world }}:latest"
name: "{{ docker_test_image_hello_world }}"
state: present
source: pull
register: present_2
@@ -41,28 +41,28 @@
- name: Make sure tag is not there
docker_image:
name: "{{ docker_test_image_hello_world }}:alias"
name: "{{ docker_test_image_hello_world_base }}:alias"
state: absent
- name: Tag image with alias
docker_image:
source: local
name: "{{ docker_test_image_hello_world }}:latest"
repository: "{{ docker_test_image_hello_world }}:alias"
name: "{{ docker_test_image_hello_world }}"
repository: "{{ docker_test_image_hello_world_base }}:alias"
register: tag_1
- name: Tag image with alias (idempotent)
docker_image:
source: local
name: "{{ docker_test_image_hello_world }}:latest"
repository: "{{ docker_test_image_hello_world }}:alias"
name: "{{ docker_test_image_hello_world }}"
repository: "{{ docker_test_image_hello_world_base }}:alias"
register: tag_2
- name: Tag image with alias (force, still idempotent)
docker_image:
source: local
name: "{{ docker_test_image_hello_world }}:latest"
repository: "{{ docker_test_image_hello_world }}:alias"
name: "{{ docker_test_image_hello_world }}"
repository: "{{ docker_test_image_hello_world_base }}:alias"
force_tag: yes
register: tag_3
@@ -74,5 +74,5 @@
- name: Cleanup alias tag
docker_image:
name: "{{ docker_test_image_hello_world }}:alias"
name: "{{ docker_test_image_hello_world_base }}:alias"
state: absent
@@ -22,31 +22,31 @@
state: absent
force_absent: yes
- name: Make sure we have {{ docker_test_image_hello_world }}:latest
- name: Make sure we have {{ docker_test_image_hello_world }}
docker_image:
name: "{{ docker_test_image_hello_world }}:latest"
name: "{{ docker_test_image_hello_world }}"
source: pull
- name: Push image to test registry
docker_image:
name: "{{ docker_test_image_hello_world }}:latest"
repository: "{{ hello_world_image_base }}"
name: "{{ docker_test_image_hello_world }}"
repository: "{{ hello_world_image_base }}:latest"
push: yes
source: local
register: push_1
- name: Push image to test registry (idempotent)
docker_image:
name: "{{ docker_test_image_hello_world }}:latest"
repository: "{{ hello_world_image_base }}"
name: "{{ docker_test_image_hello_world }}"
repository: "{{ hello_world_image_base }}:latest"
push: yes
source: local
register: push_2
- name: Push image to test registry (force, still idempotent)
docker_image:
name: "{{ docker_test_image_hello_world }}:latest"
repository: "{{ hello_world_image_base }}"
name: "{{ docker_test_image_hello_world }}"
repository: "{{ hello_world_image_base }}:latest"
push: yes
source: local
force_tag: yes
@@ -184,27 +184,27 @@
- name: Archive image
docker_image:
name: "{{ docker_test_image_hello_world }}:latest"
name: "{{ docker_test_image_hello_world }}"
archive_path: "{{ output_dir }}/image.tar"
source: pull
register: archive_image
- name: remove image
docker_image:
name: "{{ docker_test_image_hello_world }}:latest"
name: "{{ docker_test_image_hello_world }}"
state: absent
force_absent: yes
- name: load image (changed)
docker_image:
name: "{{ docker_test_image_hello_world }}:latest"
name: "{{ docker_test_image_hello_world }}"
load_path: "{{ output_dir }}/image.tar"
source: load
register: load_image
- name: load image (idempotency)
docker_image:
name: "{{ docker_test_image_hello_world }}:latest"
name: "{{ docker_test_image_hello_world }}"
load_path: "{{ output_dir }}/image.tar"
source: load
register: load_image_1